11-02-2011 09:46 AM
Dear all,
To start an application that i have developped, i would like that the user write its password in the first panel but i want that each time that user enter a character in the string control Hide_Password (see attached picture), this one is automatically convert in a "." to hide the password . The real password is saved in a second string control. It is actually what my vi is doing by using a Key Up event. But now i want to prevent any non alphanumerical character to be enter in the password, especially i do not want that the user can press the menu key as <Ctrl>, <Shift>, <Alt>, <Command>, and <Option> and also the <Left>, <Up>, <Right>, <Down>. I suppose that i have to use Key Down? event by discarding all the key that i do not want but i am sure that there is a more easy way to do it.
Do you have any idea ?
Morover, If you think that there is something wrong in my vi, please let me know.
Thanks
Philippe
Solved! Go to Solution.
11-02-2011 10:16 AM
If you don't want the display to show the users typing, why not just use Password mode on the string control.
I might misunderstand what you are trying to achieve.
11-02-2011 10:18 AM - edited 11-02-2011 10:19 AM
but why not just set the display style to *?
EDIT: Whats with the font?
11-02-2011 10:55 AM
11-02-2011 11:45 AM
Thanks for the password mode of STRING, i did not know that there is this option. It is perfect. But now i have to prevent the special key to be pressed....
11-02-2011 11:46 AM
Thanks Ben64,
it is exactly what i want... but not enough knowledge to do it so easily.
11-02-2011 11:49 AM
The real password is saved in a second string control.
One thing you shouldn't do is use a (hidden?) String control for data storage. Use the one control for data input (as a password as others have suggested) and pass the data throughout your program with a wire.