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

How to get Textbox Value from MouseButton1Down?

Asked by
DBoi941 57
4 years ago

This is from a Script.. The amount.Text is the Textbox. When I print the textbox value it says nil. I know the problem is it is not getting the updated text from the textbox I just don't know how to make that happen.

giveMoney.MouseButton1Down:connect(function()
local givePlayer = getPlayerFromName(SelectedPlayer.Text)
local Giveamount = amount.Text and tonumber(amount.Text)
print(Giveamount)
    cash.cashGive(givePlayer, Giveamount)
end)
0
can you provide the path to amount please? ArtBlart 533 — 4y
0
local amount = script.Parent.GiveMoney.Amount DBoi941 57 — 4y

Answer this question