954,500 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

displaying * in password entery

how can i make the program display * in password entery
i tried


while(getch())
{
cout<<"*";
}

but it didnt work
plz tell me how

dooda man
Newbie Poster
15 posts since May 2004
Reputation Points: 10
Solved Threads: 0
 

>but it didnt work
What were you expecting and what did it do that wasn't what you wanted? I can guarantee that you need more logic than that to mask a password entry.

Narue
Bad Cop
Administrator
15,460 posts since Sep 2004
Reputation Points: 6,464
Solved Threads: 1,401
 

You have to turn terminal local echo off. This is often specific to what kind of terminal you are using. Are you using the windows command prompt?


Ed

how can i make the program display * in password entery i tried

while(getch()) { cout<<"*"; } but it didnt work plz tell me how

cosi
Junior Poster
153 posts since Aug 2004
Reputation Points: 17
Solved Threads: 1
 

Search the forum,I remmember typing out an entire function to get passwords while displaying *'s and supporting backspace too.

In a hurry gota go...

FireNet
Posting Whiz in Training
258 posts since May 2004
Reputation Points: 108
Solved Threads: 7
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You