01-10-2014 05:04 AM - edited 01-10-2014 05:05 AM
01-10-2014 06:11 AM - edited 01-10-2014 06:12 AM
please, I repeat, PLEAAAASE use what BBSJdev wrote
feel free to report this as inappropriate, but I had to write this
01-10-2014 06:21 AM - edited 01-10-2014 06:24 AM
@pyth Made me laugh.
@babakar if your number really does have commas in then you can use a string replace to remove the commas first.
If -0.00 doesn't break the logic of your code and you are not using the number for anything else then your suggestion is fine.
You might like to do a contains rather than a first character compare unless you are absolutely sure there will be no leading spaces or characters.
In the end it's safer to turn it in to a number and do a check on whether it is a number first to catch any errant data.
01-10-2014 01:41 PM
Snippet to do what BBSJdev suggests:
lace(/,/g,""))>=0) ? Color.Black : Color.Red
01-10-2014 01:44 PM
PS: You can expand that expression to highlight items that were not a number. NaN always returns false for < > comparissons...