Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Find number within string
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00237774
Message ID:
00237784
Views:
13
>Is there a way to find a number within a string? Here's the twist, the number could be anywhere in the string, and I want to find any number...like this "#70 blue" or "70 blue" or "blue 70"
>
>any help appreciated:)

Hi John,

The first idea that comes to mind requires foxtools. It contains a function, StrFilter(). You'd use it this way:

lcnumbers = StrFilter("#70 blue", "0123456789")

lcnumbers would then equal "70".
George

Ubi caritas et amor, deus ibi est
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform