Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to create a comma-delimited memory variable
Message
De
05/05/2006 10:02:01
 
 
À
05/05/2006 09:50:56
Jay Johengen
Altamahaw-Ossipee, Caroline du Nord, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01119574
Message ID:
01119580
Vues:
22
This message has been marked as the solution to the initial question of the thread.
>Need to create a memory variable that essentially is a comma-delimited file created from a cursor. If I were to write the variable to the screen, or a report, or into a memo field, it would look like this:
>
>
>"FieldValue1","FieldValue2","FieldValue3","FieldValue4","FieldValue5","FieldValue6"
>"FieldValue1","FieldValue2","FieldValue3","FieldValue4","FieldValue5","FieldValue6"
>"FieldValue1","FieldValue2","FieldValue3","FieldValue4","FieldValue5","FieldValue6"
>
>
>I do not want to write to a physical file in order to do this.

Put this in a loop for the records required:
TCR_LF = CHR(13)+CHR(10)
TSTR = ''
FOR I = 1 TO FCOUNT()

  TSTR = TSTR + '"' + TRANSFORM( EVALUATE( FIELD(I) ) ) + '"' + IIF( I < FCOUNT(), ',', '' ) + TCR_LF

NEXT
In the End, we will remember not the words of our enemies, but the silence of our friends - Martin Luther King, Jr.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform