|
| 19 Sep 2016 02:26 PM |
How do you check if a string is a number?
Ex: if script.Parent.Text = anumber then print "the string is a number." end
|
|
|
| Report Abuse |
|
|
|
| 19 Sep 2016 02:28 PM |
if tonumber(script.Parent.Text) then -- is a number end |
|
|
| Report Abuse |
|
|
JoshRBX
|
  |
| Joined: 19 May 2012 |
| Total Posts: 8778 |
|
|
| 19 Sep 2016 02:29 PM |
if tonumber(script.Parent.Text) == nil then print("Isn't a number") else print("Is a number") end
|
|
|
| Report Abuse |
|
|
llaserx
|
  |
| Joined: 10 Dec 2011 |
| Total Posts: 53069 |
|
|
| 19 Sep 2016 02:30 PM |
| http://wiki.roblox.com/index.php?title=Global_namespace/String_manipulation |
|
|
| Report Abuse |
|
|
iIikeyou
|
  |
| Joined: 07 Mar 2012 |
| Total Posts: 1659 |
|
| |
|
llaserx
|
  |
| Joined: 10 Dec 2011 |
| Total Posts: 53069 |
|
|
| 19 Sep 2016 02:31 PM |
oh I was gon tell him put to in wiki search bar |
|
|
| Report Abuse |
|
|
|
| 19 Sep 2016 02:38 PM |
Thanks :) Now my search function works |
|
|
| Report Abuse |
|
|