Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Adding a column to an array
Message
De
30/12/2003 10:57:59
 
 
À
30/12/2003 10:43:58
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00862826
Message ID:
00862839
Vues:
12
>If I have an array like so:
>
>myarray(1,1)= "Item 1"
>myarray(1,2)= "Apples"
>myarray(2,1)= "Item 2"
>myarray(2,2)= "Oranges"
>
>and I want to add a 3rd column to the array so I will end up with the following:
>
>myarray(1,1)= "Item 1"
>myarray(1,2)= "Apples"
>myarray(1,3)= .F.
>myarray(2,1)= "Item 2"
>myarray(2,2)= "Oranges"
>myarray(2,3)= .F.
>
>How do I do it? When I redimension myarray(2,3) it looks like this:
>
>myarray(1,1)= "Item 1"
>myarray(1,2)= "Apples"
>myarray(1,3)= "Item 2"
>myarray(2,1)= "Oranges"
>myarray(2,2)= .F.
>myarray(2,3)= .F.
>
>The AINS() seems to do the same thing...
>
>TIA!

If you have the Hacker's Guide to VFP 6 they created a function called aColCopy if you look under ACOPY in the book or help file.
Charles

"The code knows no master." - Chuck Mautz
"Everybody is ignorant, only on different subjects." - Will Rogers
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform