Progress
Programming
Handbook
Procedure Properties
The procedure is the fundamental block in Progress. All types of procedures, external and internal, have certain common properties:
- They can contain all other types of blocks.
- You can execute them by name using the RUN statement.
- They can accept run-time parameters for input or output.
- They can define their own data and user interface environment (context) with restrictions depending on the type of procedure.
- They can share data and widgets defined in the context of another procedure, with restrictions depending on the type of procedure.
- They can execute recursively. That is, they can run themselves in a new context.
You can nest most blocks within a procedure. For example, you can include a DO, FOR, or REPEAT block within another DO, FOR, or REPEAT block. The number of times that you can nest blocks depends on your setting of the Nested Blocks (–nb) startup parameter. The default depth is 50. For more information on –nb, see the Progress Startup Command and Parameter Reference.
Depending on the type of procedure, you can define any number of local objects within its context, including buffers, temporary tables, queries, variables, I/O streams, frames, and many other widgets. You can reference each one of these objects within the procedure after it is defined. In addition, you can share or pass many of these objects among procedures in different ways.
The actual content of a procedure’s context and how it is managed depends on whether the procedure is an external or internal procedure, and on how you define and execute it.
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |