aspose file tools*
The moose likes Beginning Java and the fly likes How to hide user input in console mode? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "How to hide user input in console mode?" Watch "How to hide user input in console mode?" New topic
Author

How to hide user input in console mode?

Shuai Liu
Ranch Hand

Joined: Jan 25, 2002
Posts: 49
For example, when user input a password, I want the console to display **** instead of the actual input. What should I do?
THX!
Shuai Liu
Ranch Hand

Joined: Jan 25, 2002
Posts: 49
Sorry, I forgot the search for old posts.
Please just ignore this question.
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
Hello,
Out of curiousity, what's the link to the answer you found?
Thank You


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
Shuai Liu
Ranch Hand

Joined: Jan 25, 2002
Posts: 49
Actually. Somebody mentioned a post in Sun's community discussion. The author there tried to use a thread to hide user's input. It didn't solved the problem, but is the best solution I found so far.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: How to hide user input in console mode?