Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Want the last word in a string
Message
De
19/01/2004 14:26:53
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00867936
Message ID:
00868256
Vues:
17
One other way

** here's your string
lcstring = [This is the winter of our discontent.]
** count the number of spaces
icount = occurs([ ],lcstring)
** get the position of the last space
iat = atc([ ],lcstring,icount)
** pull the value after that.
?substr(lcstring, iat+1)



>How can I find the last word in a text string.
>
>Thanks
>
>Brenda
Fred Lauckner

You know, it works on my computer. I don't know what your problem is.

.Net aint so bad.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform