DOCERR: How to Use the ADEL() Command to Delete a Column

Last reviewed: June 27, 1995
Article 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(<array>,<expN>[,2]) command to delete Column Contents of an array.

MORE INFORMATION

The FoxPro Help file does not provide enough information about the second (<expN>) 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(<array>,<expN>[,2])

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

Arguments

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

          deleted.

<expN> - 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


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: June 27, 1995
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.