TextToIntegerValidate issue

TextToIntegerValidate issue

im trying to use TextToIntegerValidate(Substr(PhoneNumber,1,Length(PhoneNumber)-1))
to validate the following phone number: +456789123456
but it always returns false - is that normal?

The result of the test that you are performing is perfectly correct, because the value is higher than the upper limit of an Integer.
An Integer value in the Agile Platform is mapped to a C# Int32 data type (http://msdn.microsoft.com/en-us/library/system.int32.maxvalue.aspx) which maps directly to an "int" data type in SQL Server in terms of range (http://sqlserverplanet.com/sql/sql-server-max-int-value/).

Best Regards,
Gonçalo Martins

Hi, you can best run down an if structure that evaluates to a while loop. (if counter < Length(PhoneNumber))
Using that structure checking every character for an integer and the first character to be a "+".

Another good (perhaps even better) solution is to check client-side whether the phone number is correct using a Javascript that is bound to the input field.
Note that this last solution takes a little expertise to implement as a Widget.

thanks guys