Guided Tour

' ' ' ' ' ' ' "-->

This should take about ten minutes, and will give you an idea of how the program works.

  1. Choose Tools > Macro.

  2. Click Organizer.

  3. In the Macro Organizer window, click the Libraries tab.

  4. Click the New button and name the new library GuidedTour . Click OK.

  5. Click the Modules tab.

  6. Look in the Module list; the GuidedTour library and the default module Module1 are displayed in alphabetical order within the module list.

  7. Click the New Module button. Name the new module GuidedModule and click OK. (A module is a way of grouping macros; a library in turn groups modules.)

  8. Click the Close button of the Macro Organizer window.

  9. In the main Macro window, locate the GuidedTour library. Select the GuidedModule module you created.

  10. Click New.

  11. The Basic editing environment is displayed.

  12. Press F1 to bring up macro help. Click the Index tab and select the help for the subtraction operator, . The corresponding help will come up in the right panel. See Figure A-3.

    Figure A-3. Macro help

    graphics/afig03.jpg

  13. Copy and paste the example macro into the macro writing window. Delete the Main macro will doing so. See Figure A-4.

    Figure A-4. Pasting example macro from help into macro editing window

    graphics/afig04.jpg

  14. Click the Run icon in the macro object bar at the top of the work area.

    graphics/ainf01.jpg

  15. Click it for each line of the macro. Respond as appropriate to the dialog boxes that appear. Note messages that appear in the bottom area of the window. See Figure A-5.

    Figure A-5. Running the macro step by step

    graphics/afig05.jpg

  16. Delete subtraction example 1 by deleting the first three lines, Sub through End Sub.

  17. Change the remaining macro. Add another value and change the final print line:

     iValue3 = 7 Print iValue1 - iValue2 + (iValue1 * iValue3) End Sub 
  18. Save the macro (choose File > Save).

  19. Run the macro again.

The Basic Macro Editing Window

Figure 6 on page 965 shows the IDE, or independent development environment, where you can edit macros and access macro features. (Choose Tools > Macro, select a macro, click Edit.)

Figure A-6. Macro work area

graphics/afig06.jpg

To switch from one library to another, select a library from the list at the left side of the macro toolbar.

graphics/ainf02.jpg

To switch to a different module in the IDE, click the tab of the module you want, at the bottom of the work area.

graphics/ainf03.gif

To see a different macro, scroll up and down with the appropriate module.



OpenOffice. org 1.0 Resource Kit
OpenOffice.Org 1.0 Resource Kit
ISBN: 0131407457
EAN: 2147483647
Year: 2005
Pages: 407

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net