Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP6 Using strtran with wildcards
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00429940
Message ID:
00430033
Vues:
20
>>Do you think that the strtran function can be used with wildcards?
>
>Nope.
>
>You could probably walk through it character by character to figure out what to take out. Don't be surprised if Ed Rauh gives you a solution with RegExpr.

Mike,

Thanks to everyone for their thoughts and input. This is what I finally came up with to replace the unwanted information in each field:

***replace unwanted data
use ahorse order name
locate
scan
mlen = len(alltrim(name))
for i = 1 to mlen
if substr(name,i,1) = "("
mreplace = substr(name,1,i-1)
replace name with mreplace
endif
endfor
endscan
use
return
***end of prg
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform