Enum.Keycode help

  1. What do you want to achieve? Keep it simple and clear!
    A textbox where you can press enter to submit.
  2. What is the issue? Include screenshots / videos if possible!
    The only available enter key in the enum list, is the KeypadEnter. This is annoying because the normal enter key cannot be used.
  3. What solutions have you tried so far? Did you look for solutions on the Developer Hub?

Yes, I have looked for solutions, none of them have helped at all.

1 Like

Did you get the ScreenGui???

1 Like

just use TextBox.FocusLost.

TextBox.FocusLost:Connect(function(enter)
    if enter then
        --enter was pressed
    end
end)
3 Likes

but how does using an argument make this possible with FocusLost?

1 Like

FocusLost passes 2 arguments, whether enter was pressed and what keycode it was. So, using that argument, you can tell if they pressed enter. Check more out here.

1 Like

oh, ill test it out then! Cheers!

1 Like

Oh i see, so that feature is built in.

1 Like