Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Why does this not change the text?

script.Parent.Parent.StartFill.MouseButton1Click:connect(function()
	local plr = game.Players.LocalPlayer
	local text1 = script.Parent.PlrName.Name.Text
	local text2 = script.Parent.Age.Text
	local Age = plr.AccountAge
	local Name = plr.Name
	local gui = script.Parent
	text1 = (Name)
	text2 = (Age)
	script.Parent.Parent.StartFill.Visible = false
	script.Parent.Parent.CheckApp.Visible = false
	gui.Visible = true
	gui:TweenSize(UDim2.new(0,822,0,562), "In", "Quint", 1)
end)

I tried this but it didn't work, it is supposed to change a text label in the player's GUI but it seems to not work. Any help would be appreciated!

1 answer

✓ Accepted answer
script.Parent.Parent.StartFill.MouseButton1Click:connect(function()
    local plr = game.Players.LocalPlayer
    local Age = plr.AccountAge
    local Name = plr.Name
    local gui = script.Parent
    script.Parent.PlrName.Name.Text = (Name)
    script.Parent.Age.Text = (Age)
    script.Parent.Parent.StartFill.Visible = false
    script.Parent.Parent.CheckApp.Visible = false
    gui.Visible = true
    gui:TweenSize(UDim2.new(0,822,0,562), "In", "Quint", 1)
end)

1 comment

0

It gave me this error "Players.ThatGamer883.PlayerGui.Applications.Main.FillOut.Tween2:6: attempt to index field 'Name' (a string value)"

This discussion is preserved as it was. New answers, comments, and votes are closed.