Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Password font for Foxpro

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I am working on a FoxPro project for my school and I need to find a font that displays letters like asteriks (eg.****). I'd be greatful if you could tell me where to find such a font?
 
If this is FP2.6, you might be able to set the foreground color to be the same as the background color. [sig]<p>Robert Bradley<br><a href=mailto: > </a><br><a href= - Visual FoxPro Development</a><br> [/sig]
 
Alihb
See if this function still works.
[tt]
*/***************************************************************************
*/Program : Function Password
*/System :
*/Purpose : Checks a Entered String against a password and return a logical
*/Syntax : lcPassword = Password(Row,Clm)
*/Returns : string , password enrtered
*/Parameter : Integer - Row - The screen row where the input is to be
*/ : Integer - Clm - The screen column where the input is to be
*/Defaults : Row = 0
*/ : Clm = 0
*/Requires : Nothing
*/Changes : Nothing
*/Calls :
*/Version : 1.0
*/Dated : 05/28/1989
*/Written By: David W. Grewe
*/***************************************************************************
*& Utility - Security
*/***************************************************************************
*/ Record Of Change
*/
*/***************************************************************************
parameters pnRow , pnCol
private pnRow , pnCol , p_Ver
private L_PARA , LcMsg , LcCol , LcPassWord , LnKEY , LcDISPLAY
L_PARA = parameters()
if L_PARA < 2 .or. type('PnROW') <> &quot;N&quot; .or. type('PnCOL') <> &quot;N&quot;
pnCol = int((scols()-40)/2)
pnRow = int((srows()-4)/2)
endif
*****
*****
* Initialize the password variable so it can be retrieved.
LcPassWord = &quot;&quot;
LcMsg = &quot;Enter Password&quot;
LcCol = len(LcMsg) + 25
pnRow = iif(pnRow < 0, int((srows()-4)/2), iif(pnRow > srow(), srow()-4, pnRow))
pnCol = iif(pnCol < 0, int((scols()-40)/2),iif(pnCol > scol(), scol()-44, pnCol))
LnKEY = 0
LcDISPLAY=&quot;&quot;
set escape off
set cursor off
define window password from pnRow,pnCol to pnRow+2,pnCol+30 system noclose nogrow nofloat nozoom nomdi color scheme 8
activate window password
@ 0,0 say LcMsg
do while len(LcPassWord) < 10
LnKEY=inkey()
do case
case LnKEY = 13 && Return key
exit
case LnKEY = 27 && Escape key
LcDISPLAY = ''
LcPassWord = ''
case LnKEY = 127 && Backspace key
LcPassWord = left(LcPassWord, len(LcPassWord)-1)
LcDISPLAY = replicate(&quot;*&quot;,len(LcPassWord))
case between(LnKEY,48,57) && a Number
LcPassWord = LcPassWord + chr(LnKEY)
LcDISPLAY = replicate(&quot;*&quot;,len(LcPassWord))
case between(LnKEY,65,90) && a Upper Case Letter
LcPassWord = LcPassWord + chr(LnKEY)
LcDISPLAY = replicate(&quot;*&quot;,len(LcPassWord))
case between(LnKEY,97,122) && a Lower Case Letter
LcPassWord = LcPassWord + chr(LnKEY)
LcDISPLAY = replicate(&quot;*&quot;,len(LcPassWord))
endcase
@ 0,len(LcMsg)+2 say LcDISPLAY
enddo
set escape on
set cursor on
release window password
release pnRow , pnCol , PcVER
release L_PARA , LcMsg , LcCol , LnKEY , LcDISPLAY
return LcPassWord[/tt] [sig]<p>David W. Grewe<br><a href=mailto:Dave@internationalbid.net>Dave@internationalbid.net</a><br>[/sig]
 
The background and foreground colour being the same is OK. But if you highlight the field then the text is displayed.

You have to be careful with using fonts because if a machine does not have the font you specified installed then it can default to a normal text font.

Mark [sig][/sig]
 
There is a public domain subroutine for just this purpose. I can email it to you if you want it. [sig]<p>Mike Wood<br><a href=mailto:mikewood@mpwonline.com>mikewood@mpwonline.com</a><br><a href= > </a><br> [/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top