Try a blank password first. - If no password, do not prompt for one. Just use the file (probably prompting for a pass at next login)

This commit is contained in:
Tim Young 2017-08-13 16:52:13 -05:00
parent 6a51ed058a
commit 6fd86bd916

View File

@ -1755,9 +1755,11 @@ namespace EduNetworkBuilder
{ //Load a starting, or a new user
int counter = 0;
PersonClass tUser = null;
while (counter < 3)
while (counter < 4)
{
string tPass = NB.TextPromptBox("Enter a password", Properties.Resources.NBIco, true);
string tPass = "";
if(counter > 0) //First try an empty password
tPass = NB.TextPromptBox("Enter a password", Properties.Resources.NBIco, true);
string tUserName = Path.GetFileNameWithoutExtension(filename);
string PasToUse = tUserName + tPass;
tUser = PersonClass.TryLoad(filename, PasToUse);