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

TextLabel text changed, help? [UnSolved]

We all know that you can type inside a TextBox right?

Well, when I change the text to create[Part] this script does not work..

if script.Parent.Text == "create[Part]" then
	part = Instance.new("Part")
	part.Parent = game.Workspace
end

Thank you!

2 answers

✓ Accepted answer

Try this!

script.Parent.FocusLost:connect(function()
	if script.Parent.Text == "create[Part]" then
		part = Instance.new("Part", game.Workspace)
	end
end)

I heard it didn't work so if it is in script try local script else I don't know, sorry!

11 comments

0

I am sorry if this doesn't work but I'll try again!

0

It didn't work, but I +1'd because you helped.

0

Okay I'll keep trying because you +1'd instead of -1'd!

0

I fixed it!!

0

It connects when you click Enter or click somewhere else other than textbox and it checks if the text == create[Part]

0

Thanks!!! Yay!

0

You're welcome, tell me if you need anything else. I'll be free to help.

0

It didn't work because it would start 1 time at start of server. You had to connect it when it changes or something.

0

It works in Test, but it doesn't work in the real game. Screw ROBLOX!

0

Oh. Put it in local script then try. Or if you did do local script put it in a script.

0

hahaha I am stupid! I forgot to inform you IT DOES need localscript! So try with localscript I GUARANTEE it'll work!

Answer

Your question doesn't seem enough for me to get

But if you mean you want it to be unable for the other players To change the text to another writting I suggest use text label in advanced objects not text box.

Did i get your problem fixed or i got the wrong idea if i did got it all wrong then sorry your question doesn't give a lot of details.

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