EXTERNAL Command
| Visual FoxPro 9.0 SP2 |
| EXTERNAL Command |
| See Also |
|
Alerts the Project Manager Window to an undefined reference.
EXTERNAL FILE FileList | ARRAY ArrayList | CLASS | FORM | LABEL | LIBRARY | MENU | PROCEDURE | QUERY | REPORT | SCREEN | TABLE |
Parameters
- FILE FileList
-
Specifies that the file you include in an indirect file reference or macro substitution is a stand-alone file, such as a text file, .BMP bitmap file, and so on. FileList may contain a list of file names separated by commas.
- ARRAY ArrayList
-
When an array is created in a program and then used in a lower-level program, include ARRAY with the array name in the lower-level program. ArrayList may contain a list of array names separated by commas.
In the following example, the first program creates an array named
gaInvoice. The array is initialized and a lower-level program nameddispinvois called.dispinvodisplays the contents of the array created in the higher-level program. The command EXTERNAL ARRAY GAINVOICE is included to alert the Project Manager.
Copy CodeDIMENSION gaInvoice(4) STORE 'Paid' TO gaInvoice DO dispinvo *** Program dispinvo *** PROCEDURE dispinvo EXTERNAL ARRAY gaInvoice ? gaInvoice(1) ? gaInvoice(2) ? gaInvoice(3) ? gaInvoice(4) RETURN *** End of dispinvo program ***
When an array is passed to a user-defined function or procedure, the corresponding array in the user-defined function or procedure must be identified to the Project Manager. Include the ARRAY option with the name of the array included in the PARAMETER statement.
Copy CodeDIMENSION gaArrayOne(2) && Create an array EXTERNAL ARRAY gaArrayTwo && Name of the array used in the UDF SET TALK OFF STORE 10 TO gaArrayOne(1) STORE 2 TO gaArrayOne(2) = ADDTWO(@gaArrayOne) && Pass the array by reference to a UDF FUNCTION ADDTWO PARAMETER gaArrayTwo CLEAR gaArrayTwo(1) = gaArrayTwo(1) + 2 gaArrayTwo(2) = gaArrayTwo(2) + 2 ? gaArrayTwo(1) ? gaArrayTwo(2)
- CLASS
-
Specifies that the file you include in an indirect file reference or macro substitution is a visual class library.
Copy CodeEXTERNAL CLASS myvclass && CLASS myvclass must exist STORE 'myvclass' TO gcClassFile MODIFY CLASS (gcClassFile)
- FORM
-
If a Form definition file is included in an indirect file reference or macro substitution, include FORM and the Form file name. FORM is identical to SCREEN.
Copy CodeEXTERNAL FORM dataentr && FORM dataentr must exist STORE 'dataentr' TO gcFormFile DO FORM (gcFormFile)
- LABEL
-
Specifies that the file you include in an indirect file reference or macro substitution is a label definition file.
Copy CodeEXTERNAL LABEL Maillabl && LABEL FORM Maillabl must exist STORE 'Maillabl' TO gcLabelFile LABEL FORM (gcLabelFile) PREVIEW
- LIBRARY
-
Include LIBRARY when a library file is referenced by indirect file referencing or macro substitution in SET LIBRARY.
Copy CodeEXTERNAL LIBRARY regress && LIBRARY regress must exist STORE 'regress' TO gcStatFunc SET LIBRARY TO (gcStatFunc)
- MENU
-
If a menu definition file is included in an indirect file reference or macro substitution, include MENU and the menu file name.
Copy CodeEXTERNAL MENU pickfile && MENU pickfile must exist STORE 'pickfile' TO gcSysMenPad MODIFY MENU (gcSysMenPad)
- PROCEDURE
-
Identifies an external procedure or user-defined function.
Copy CodeEXTERNAL PROCEDURE delblank && PROCEDURE delblank must exist STORE 'delblank' TO gcTrimBlanks DO (gcTrimBlanks) WITH 'A B C D E'
- QUERY
-
Specifies that the file you include in an indirect file reference or macro substitution is a query file.
Copy CodeEXTERNAL QUERY sales && QUERY sales must exist STORE 'sales.qpr' TO gcSalesFile DO (gcSalesFile)
- REPORT
-
Specifies that the file you include in an indirect file reference or macro substitution is a report definition file.
Copy CodeEXTERNAL REPORT overdue && REPORT overdue must exist STORE 'overdue' TO gcReportFile REPORT FORM (gcReportFile) PREVIEW
- SCREEN
-
If a form definition file is included in an indirect file reference or macro substitution, include SCREEN and the screen file name. SCREEN is identical to FORM.
Copy CodeEXTERNAL SCREEN dataentr && SCREEN dataentr must exist STORE 'dataentr' TO gcScreenFile MODIFY SCREEN (gcScreenFile)
- TABLE
-
Specifies that the file you include in an indirect file reference or macro substitution is a Visual FoxPro table.
Copy CodeEXTERNAL TABLE customer && Table customer must exist STORE 'customer' TO gcMyTable USE (gcMyTable)
Remarks
See Also
© , 1996-2020 • Updated: 11/10/20
Comment or report problem with topic
Microsoft Visual FoxPro 9 SP2 Help file, VFPX Edition v1.08