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

Need some help with text labels text changing?

Asked by 3 years ago
Edited 3 years ago

So I'm making a script that when i say something in the chat it changes a text box to that text but the problem i having is it says that "Text is not a valid member of Blank" Please let me know if there is any other info you need

local typeVal = script.Parent.Parent.Parent.ReplicatedStorage.NewShit.Rep["Remotes/Var"].Var.One.value
local Textbox = script.Parent.Parent.Parent.StarterGui.Gui.Blank
local plr = game:GetService("Players")

game.Players.PlayerAdded:connect(function(player)
    local msg = player.Chatted:connect(function(msg)
        Textbox.Text = "fun"
    end)
end)

NEW CODE

1 answer

Log in to vote
0
Answered by 3 years ago
Edited 3 years ago

On line 8 !! Change text to Text

Textbox.Text = ("fun")

IF that was not what you meant continue reading, On the above however, you declared text as Textbox.Property... so did you mean

Textbox.Textbox.Property = ("fun")

If this was what you meant, you cannot declare Textbox.Property as a variable, you have to type out the full Textbox.Textbox.Property = ("fun") instead. And also there isn't a property named fun so I believe that's not what you meant

[edit] after three days (sorry)

your line 1 needs to be changed to local typeVal = script.Parent.Parent.Parent.ReplicatedStorage.NewShit.Rep["Remotes/Var"].Var.One.Value

your v in Value isn't capitilized

0
the text label wont change text here's new code james_tnt7salt 2 — 3y
Ad

Answer this question