I am making a login page, when I get user input its fine. The credentials are going to be stored in a file. The values stored in file get set as the string of the NSTextField
.
If I use NSSecureTextField
the password is never seen by user when I read the values from my file. I searched but was unable to view the password in my UI. I want to know if there is any way to make the password visible in my NSSecureTextField
. I just tried it with NSTextField
but then the user can see passwords being entered.
As this comment says if you would just like to set the value of an NSSecureTextField
just use setStringValue:
on it. If you would like to be able to read what is in the NSSecureTextField
you can call setEchosBullets:
and pass false
to make it show the actual text.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With