Search code examples
javaswingauthenticationjtextfield

JTextField Java


I have a java application that also has a login system implemented into it. On the login page I have a userName and password textfield, is there anyway for the textfield to not show the password when it is being typed, instead of it showing the text as it is being type, I want it to show a " * " for each letter/number, etc typed.

Thanks


Solution

  • Look into JPasswordField. Here's the Oracle docs: http://docs.oracle.com/javase/tutorial/uiswing/components/passwordfield.html.