Check if text is numeric

Get help using Construct 2

Post » Fri Jan 11, 2013 9:10 am

Is it possible to check if an input is numeric ?

ATM I send an Ajax Request to a php file there I check if the text is numeric or not... Is there a way to do that in Construct ? Found no expression for that.      
B
15
S
6
G
6
Posts: 512
Reputation: 5,555

Post » Fri Jan 11, 2013 7:06 pm

Do a system compare:
Text.Text = str(int(Text.Text))
B
91
S
31
G
99
Posts: 5,192
Reputation: 65,670

Post » Mon Jan 14, 2013 8:22 am

Thank you that's genius.

Text = Text -> to Int -> to String

Fuu = Fuu -> false -> false

1 = 1 -> 1 -> 1

B
15
S
6
G
6
Posts: 512
Reputation: 5,555


Return to How do I....?

Who is online

Users browsing this forum: imhotep22, NN81, pcprice76, winon, Xh3maa and 4 guests