Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dynamic Field Names?
Message
De
11/09/2000 14:12:37
 
 
À
11/09/2000 13:59:59
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00415009
Message ID:
00415019
Vues:
24
>I want to parse one feild into an undefined number of other fields named desc1, desc2, desc3... descX. I would like to address those fields from within a loop using 'desc' and appending a numeric variable that I can increment every time through the loop. Any idea what the syntax would be for that?
>
>This might be a little clearer.
>
>

Use a named expression
See the bolded lines
I'm assuming you know how you will exit the loop - but I would suggest using a FOR loop instead.

>
>X = 1
>
>do while loop_condition = TRUE
>

lcField = "desc" + allt(str(x))
replace (lcField) with contents


>
>X = X + 1
>
>Loop
>EndDo
>
>
>Thanks.
>
>Ian
Insanity: Doing the same thing over and over and expecting different results.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform