Hi Tracy,
You can create a loop to go through each and every one single character of your initial string, using the Mid() function and then test that single obtained character to be a number or not by using the IsNumber() function. If it's a number, then you append it to a new string that you create. At the end of the loop, in your new string that only contains numbers, you can use for example the Long() functtion to convert that to a number. (I don't know if you might have decimals and thousands separators also in the string. In that case it becomes a bit more complicated, since you would have to determin if a dot and or comma is just another character in your string or if it's part of a number). You might also have to include dashes '-' to form part of the number or not ...
Can't do any sample code right now, since not able to connect to powerbuiilder at the moment, but let me know if you need a sample of code and I can do it tomorrow.
regards,
MiguelL
Nice and simple, but I think there's something missing in "If Match(Left(ls_string,"^[0-9]+$") Then" ..
I haven't tried it (5 am), but it looks like the "Left(" part needs the "li_i" added a closing bracket?
I need coffee now!
:)
regards