Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

[SOLVED] How would you figure out if a value is a integer?

Asked by 6 years ago
Edited 6 years ago

I have come across multiple instances where I would need something like this.

For example, I have recently made a banning system where you can either input a player UserID or a player's username. I was wondering how you would be able to tell if that value (which would be a textbox) was a number or a string value.

This would be very helpful and I thank you in advance.

1
Check if tonumber() returns nil: if tonumber(textbox.Text) then Amiaa16 3227 — 6y
0
Thanks! It worked :D Creeperman1524 120 — 6y

Answer this question