Access فيربونى به رنامه ى

Page 305

Chapter Ten: Working with Macros Chapter Objectives: •

Create and run a macro

Create a collection of macros in a single macro group

Assign a macro to a button on a form

Assign a macro keystroke combination

Create a conditional IF/THEN expression

Chapter Task: Create macros that automate database tasks If you find yourself doing the same routine task over and over again, you might want to consider creating a macro to complete the task for you. A macro helps you perform routine tasks by automating them. Instead of manually performing a series of time-consuming, repetitive actions, you can record a single macro that does the entire task all at once for you. For example, instead of clicking the Reports icon in the Objects bar in the database window, finding and opening a specific report, printing it, and then closing it, you could create a macro to print the report with the click of a single button. A macro is a set of one or more actions that perform a particular operation, such as opening a form or printing a report. Macros can help you to automate common tasks. For example, you can run a macro that prints a report when a user clicks a command button. In a way, you can think of macros as a very simple introduction to programming because you can use them to create automated tasks and somewhat complex procedures. Best of all, you don’t have to know a single line of code—Access provides you with everything you need to write a macro.

; Prerequisites • How to use menus, toolbars, dialog boxes, and shortcut keystrokes. • How to open and modify database objects.


Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.