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

Forcing TextBox to lose focus? [SOLVED]

EDIT: RoboFrog's idea didn't work out for me. Anyone else got any other ideas on how to fix/solve this? Thanks in advance.

Hi guys, I was wondering if it was possible to force a TextBox GUI object to lose focus.

Not really much that I can elaborate on this but I am making a chat delay for my chat and I need it so that you can't click on the chat bar while the delay is active. (With the delay being to just set a variable to either true or false)

Any help is appreciated, thanks!

2 answers

✓ Accepted answer

Considering I'm reading this right, while the delay is active, you could always place another GUI element over the text box. I'm pretty sure you can't activate text boxes if they're under other GUI elements.

EDIT: Also set the TextBox"visible" property to false.

4 comments

0

On second thought, it didn't work. I could still click the TextBox. Any other ideas?

0

Edited previous comment.

0

You could always do the same thing, but instead of just placing the GUI element over it, you could make the text box's "visible" factor to false. I know for a fact that it can't be interacted with while that is false.

0

Right. I was trying to find a more "elegent" solution but that will do. I'll try that later. EDIT: Works, thank you and Zeptix too!

RoboFrog is correct. The best way to do this would be to set the Visible property to false at the time you need. Remember to NOT simply make it invisible with transparency, because then users will still be able to interact with it. Use the Visible property.

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