hidePasswordCheckbox.addItemListener(new ItemListener() {
public void itemStateChanged(ItemEvent e) {
if (e.getStateChange() == ItemEvent.SELECTED) {
httpProxyPassword.setEchoChar('*');
} else {
httpProxyPassword.setEchoChar((char) 0);
}
}
});
You have to use httpProxyPassword.setEchoChar((char) 0);
for that.
Here httpProxyPassword
is a name of textbox you can use as per your's.