How To Save Info From Previous Uses of Program???

Jul 28, 2016 at 4:43am
So, I was wondering two things.
First, are username password systems coded with C++ or another language of code?
Second, how would you store this information. For example, if the first time you open the program it asks you for a username and password, but the second time you open the program it asks for a username and password and will only run the code if the username and password are the same as the username and password entered the first time.
Jul 28, 2016 at 5:26am
Hi,
To do that, you need to know about WinAPI programming.

For example :
Password : ********
Jul 28, 2016 at 11:00am
Second, how would you store this information.

You can store the information in a file or in the registry.

The logic is quite simple. When the program starts check if either the file or registry key exists.
If yes that means it's not the first time. So you ask the user for name and password and compare it with the stored ones.

If not the first time then you ask for username and password and store it either in the file or in the registry. Be aware of the fact that the user can delete the registry key or file and pretend to run it the first time.
Topic archived. No new replies allowed.