Microsoft KB Archive/126438

{| = DOCERR: How to Use the ADEL Command to Delete a Column =
 * width="100%"|

ID: Q126438

The information in this article applies to:


 * Microsoft FoxPro for Windows, version 2.6a
 * Microsoft FoxPro for Macintosh, version 2.6a
 * Microsoft FoxPro for MS-DOS, version 2.6a
 * Microsoft FoxPro for UNIX, version 2.6

SUMMARY
This article describe how to use the ADEL( ,[,2]) command to delete Column Contents of an array.

MORE INFORMATION
The FoxPro Help file does not provide enough information about the second () and the third (2) arguments in the ADEL command. Also, there is no information or example for deleting the contents of an array column using the ADEL command. This article illustrates the information about the ADEL command that is missing from the FoxPro Help file documentation.

Syntax
ADEL( ,[,2])

Deletes an element from a one-dimensional array or a row or column from a two-dimensional array.

Arguments
- Specifies the array from which the element, row, or column is

deleted.  - Specifies the number of the element, row, or column to delete from the array. You must include the optional 2 argument to delete a        column from the array.

2 -     Deletes the contents of a column from the array.

Example
x=ADIR(mylist) DISPLAY MEMORY LIKE mylist y=ADEL(mylist,5,2) DISPLAY MEMORY LIKE mylist

In this example, you create a array with five columns, and then display the array to the screen. Next, you delete the contents of the fifth column and it is filled with .F. as stated in the ADEL topic of the FoxPro Help.

Additional reference words: FoxWin FoxDos FoxMac FoxUnix 2.60a KBCategory: kbprg kbcode kbdocerr KBSubcategory: FxprgGeneral
 * }