how to accept an value from console without echoing it?
which means i want to receive an input in my program but don't want its user to have a look at what he/she is typing....
can any body tell me what inbuilt method can serve this purpose.....
Java1.6 introduces the Console class. It has a readPassword() method which does not echo the input. (be careful that System.getConsole() may return null).
Try the password method of the java.io.Console class, but remember that only works when your application is started from the command line.
There are PasswordField and JPasswordField classes in awt and Swing, which might help you.