passwords in fields?

Jeanne A. E. DeVoto jeanne at runrev.com
Tue Jan 22 02:50:00 EST 2002


At 10:19 PM -0800 1/21/2002, Chipp Walters wrote:
>      Not sure how to  create a field where typing a password is
>automatically replaced with *********  during the typing? Is this not a
>property  of a field? Like set the  password of fld 1 to true? Any ideas?
>  thx, Chipp

It's not a field property, no. (You may be thinking of the ask password
command - this puts up an ask dialog that replaces typed text with
asterisks.)

To do it in a field, I'd use a rawKeyDown handler in the field that takes
typed characters and appends them to a local variable or custom property of
the field, and inserts an asterisk in the field. Backspace you'd handle by
removing a character from the local or custom property and removing an
asterisk.

Or you could take a look at the card script in the ask password dialog.

--
Jeanne A. E. DeVoto ~ jeanne at runrev.com
http://www.runrev.com/
Runtime Revolution Limited - Power to the Developer!





More information about the use-livecode mailing list