But that's just my point...
why is the $ included in that list?
I expect the VAL function to
always return numeric.. but if I put a $ in front of the string it suddenly returns Currency
In my case I have a variable which I am reading from a .ini file
lnRefresh = Val(GetIniStr("Refresh", "c:\temp\fred.ini"))
Set refresh to (lnRefresh)
I know that GetIniStr always returns a String, but in this case it was returning a string with a $ symbol at the front (file corruption I think).
Of course I can work around this but I just found it irritating that the Val function does not work as described in help (or Hackers guide).
Regards
Will
>Hi!
>
>val() function do not recognize the currency symbol(s) before number. Any character except number, +- and $ are considered as wring character so zero returned. If you want it recognize currency symbol(s) and return th Y type in such case, use something like following:
>
>? val(STRTRAN("£123.23",SET("currency"),"$"))
Will Jones