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

How do i use the function tostring to convert number to string?

Asked by
CjayPlyz 643 Moderation Voter
5 years ago
Edited 5 years ago

The wiki just doesn't explain enough for me to understand.

Because of this i'm only using this alternative to make my script work.

if TextNumber3.Text == (""TextNumber1.Text + TextNumber2.Text.."") then -- Only a part of my script, should be enough
0
What are you trying to do? Vulkarin 581 — 5y
0
um, tostring converts things into a string, not tonumber theking48989987 2147 — 5y
0
oh um.. well.. i'm changing the question wait. CjayPlyz 643 — 5y
0
well its fixed now XD CjayPlyz 643 — 5y

1 answer

Log in to vote
1
Answered by 5 years ago

Just do this by using the function tostring on the number. However, the Text property of TextLabels, TextButtons and TextBoxes is a string so you really should not worry about that.

if you want to convert it to a number you just use the function tonumber

Hope this helped you.

0
does that mean i have to make a variable for it? CjayPlyz 643 — 5y
0
You just use `tostring(number)` and it should work as you wish 1TheNoobestNoob 717 — 5y
Ad

Answer this question