Array Manipulation
FoxPro has quite a few functions for working with arrays; all of them begin with the letter "A" (we don't think it's scarlet, though). These functions can be loosely divided into various groups. The first group is simply for working with an array itself. This group includes ACOPY(), ADEL(), AELEMENT(), AINS(), ALEN(), ASCAN(), ASORT() and ASUBSCRIPT(). Next, we have functions that collect information about the general environment and store it in an array. These are ADIR(), AError(), AGetFileVersion(), AFONT(), AMouseObj() and APrinters().The third group gathers information about the data environment and stores it in an array. These functions are ADatabases(), ADBObjects(), AFIELDS() and AUsed().The last group is a set of functions that put information about objects (the OOP kind of objects) into an array. In this group, we find AClass(), AGetClass(), AInstance(), AMembers(), ASelObj(), and AVCXClasses().Finally, we have one function that doesn't fit into any of the other groups—ALines().Here's a list of the various array functions with a quick description of each so you can figure out which one to go look up.
Function |
Description |
Fills array with class hierarchy for object. |
|
Copies from one array to another. |
|
Fills array with list of open databases. |
|
Fills array with contents of database. |
|
Deletes items from array. |
|
Fills array with list of files. |
|
Converts (row, column) format to element format. |
|
Fills array with error information. |
|
Fills array with field list. |
|
Fills array with font information. |
|
Lets the user choose a class and returns info about the class in an array. |
|
Fills array with version information for an EXE or DLL. |
|
Inserts items into array. |
|
Fills array with instances of object. |
|
Computes size of array. |
|
Fills array with the lines of a character string. |
|
Fills array with members of object. |
|
Fills array with information about mouse position. |
|
Fills array with list of printers. |
|
Finds item in array. |
|
Fills array with selected objects. |
|
Sorts array. |
|
Converts element format to (row, column) format. |
|
Fills array with list of tables in use. |
|
Fills array with information about classes in a class library. |