: ) Thanks I will modify my code too ...
-----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Peter M. Brigham, MD Sent: Friday, 19 August 2011 11:19 PM To: How to use LiveCode Subject: Re: Ask Password and Login Screen On Aug 18, 2011, at 8:54 PM, John Tregea wrote: > Hi, > > I used a different approach to this question as the bulleted text font > didn't seem that secure. The following code just traps the characters > entered into a field and replaces them with "*" while storing the actual > string into a global variable. > > on openfield > global gThePass > put empty into gThePass > put empty into fld "password" > pass openfield > end openfield > > on keydown thekey > global gThePass > put thekey after gThePass > put "*" after field "Password" > end keydown > > on backspacekey > global gThePass > put empty into fld "password" > put empty into gThePass > end backspacekey > > > on returninfield > global gTheUser > send mouseup to btn "Login" > exit returninfield > end returninfield > > The only downside is that if the user makes a mistake and types a backspace > they have to start all over again. Just modify the backspace handler: on backspacekey global gThePass delete char -1 of fld "password" delete char -1 of gThePass end backspacekey and it will work as you would expect. -- Peter Peter M. Brigham [email protected] http://home.comcast.net/~pmbrig _______________________________________________ use-livecode mailing list [email protected] Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode ----- No virus found in this message. Checked by AVG - www.avg.com Version: 10.0.1392 / Virus Database: 1520/3843 - Release Date: 08/18/11 _______________________________________________ use-livecode mailing list [email protected] Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
