qck.hlp (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
Passing Forms and Controls
                                                 Contents  Index  Back
──────────────────────────────────────────────────────────────────────────────
 Passing Forms and Controls
 
 ■ Procedures can accept forms and controls as formal parameters. If passed,
   they must be defined as FORM or CONTROL. For example:
 
         SUB ChangeCaption (NewCap AS FORM, Caption$)
             (statements)...
         END SUB
 
         SUB DoIt (MyControl AS CONTROL)
             (statements)...
         END SUB
 
 ■ All properties and controls can be referenced on a passed form or control
   variable. However, a run-time error occurs if either:
   • The passed form does not contain the referenced control
   • A referenced property does not exist for a passed control parameter
 
 ■ You can use the IF TYPEOF statement to determine the type of control
   passed to a procedure. See: IF TYPEOF Statement