Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Replicate
Message
 
 
À
09/12/2003 15:04:58
Andy Roth
Neyenesch Printers
Californie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00857361
Message ID:
00857484
Vues:
23
>I want to replacte a string would would like to display in the string
>the number the replication is in the string
>
>Ouput example:
>Replicate("Form"+STR(replication number),3)
>Form 1
>Form 2
>Form 3
>
>Is there a way to access the counter for Replicate() to do this?

Here's code based on Re: Does an inverse of ALINES() exist? Message #732084 that produces required result.
? NVL(_VFP.SetVar("nSub", 1), "") + Textmerge( ;
  Replicate('Form <<STR(nSub) + NVL(_VFP.SetVar("nSub", nSub+1), "")>><<Chr(13)+Chr(10)>>', 3))
--sb--
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform