Panorama organizes programming code into procedures. Each procedure contains the code for performing a particular task. (See Code to learn about writing the code itself.)

Panorama has both named and anonymous procedures.

Named Procedures

A named procedure is a self contained entity. It can be included in menus, and called as a subroutine from other procedures. Named procedures are accessed from the View Menu.

To learn how to create a named procedure, see View Menu. To learn about the tools available for editing a named procedure see Procedure Editor. To learn how named procedures can be used in the Action menu see Action Menu.

Anonymous Procedures

An anonymous procedure is embedded in another entity – either a database field, a form, a form object, or other program code. These procedures cannot be accessed or used independently from the entity they are embedded into.

This example shows an anonymous procedure embedded into the Lot field of this database.

When a value in the field is edited, the procedure code is triggered. If the building size is larger than the lot, the code will display an alert message.

As shown in the illustration above, anonymous procedures are set up in an inspector panel on the right edge of a window. This is great for short bits of code, but for more complex code you may want to put some or all of the code in a named procedure. This allows you to take advantage of the more powerful editing and debugging tools available for named procedures (see Procedure Editor). To do this, simply use the call statement, which allows you to call any named procedure as a subroutine.

In the example above there is no code in the anonymous procedure except for the call statement, but you can include a mix of both regular code and calls to named procedures.


See Also


History

VersionStatusNotes
10.0UpdatedCarried over from Panorama 6.0, now allows anonymous procedures.