Download Programming with Reflection: Visual Basic User Guide
Transcript
Programming Fundamentals 19 Additional concepts in Visual Basic for Applications and stand-alone Visual Basic include: · Objects · Forms · Events The Visual Basic Help covers these and other topics under the heading Visual Basic Conceptual Topics in the Help Contents. (Instructions for viewing this Help are on page 3.) If you are new to BASIC programming, you may want to use a guide that is organized for beginners before you tackle the Help. Many books are available that cover the fundamentals of programming with Visual Basic and Visual Basic for Applications. Understanding Visual Basic Projects A macro is the entry point to a Visual Basic project. When you run a macro, Visual Basic executes the commands in that macro. Commands within a macro can use other components of the same project. This means that a macro can run other macros, display forms, or execute user-defined procedures—if these components are within the same project. In addition, macros in one project can also run macros in other referenced projects. When you open the Visual Basic Editor, you can see the elements of your current project by using the Visual Basic Project Explorer. The term scope refers to the availability of variables, constants, procedures, and forms defined in one part of a project for use by other procedures in your project. See Scoping levels in the Visual Basic Help for more information. (Instructions for viewing this Help are on page 3.) The Components of a Reflection Project A Reflection Visual Basic project contains a number of components, including Objects, Modules, Forms, and Class Modules. Reflection Objects The Reflection objects component contains the module that defines the methods and properties that make up the Reflection object. If you select ThisSession in the Project Explorer, the Properties window lists all the properties for Reflection’s Session object. This list is similar to the list you see when you select Macro syntax in Reflection’s View Settings dialog box. Changes you make in either location affect the current Reflection settings.