Use the Code window to write, display, and edit form, event, and method code. You can open as many Code windows as you want, so you can easily view, copy, and paste the code from different forms.
The Code window appears when you double-click a form or form control in the Form Designer, double-click in the Data Environment Designer window, or double-click an event or method in the Properties Window. Doing this has the same effect as choosing the Code command on the View menu.
Any text added to a method or event in a Code window will cause that class to have Override behavior for the method or event. Therefore, code for the method or event in a parent class will not be executed by default (it must be explicitly executed). This includes non-executable comment lines that begin with "*".
- Lists the current form, form set, data environment, toolbar objects, cursor, relation, and all the controls on the current form.
Lists all the events recognized by Microsoft Visual FoxPro for the form, form set, data environment, cursor, relation, or control displayed in the Object box. When you select an event or method from the Procedure box, the parameters passed to the event or method (if any) are displayed in the editing region of the Code window. Event names in boldface text contain code. Access and Assign methods created for a property are also displayed in the Procedure box.
Tip: If you need help on syntax for functions, statements, properties, events, or methods while working in the Code window, type the keyword or the property, event, or method name, select it, and press F1 for online Help. You can also select an event or method in the Procedure box and press F1 for information about the selected event or method. Press PAGE DOWN to jump to the next event or method that has code in it.