From fa45156233a5c14d801a032402d6a79705d1e6b8 Mon Sep 17 00:00:00 2001 From: Roland Drabesch Date: Tue, 21 Oct 2025 12:55:20 +0200 Subject: [PATCH] fix connection screen --- Common/LaaPackages | 2 +- Common/Ui/GenesisToolBox/FrmLowLevelTools.cs | 22 +++++++++++++++----- Common/Ui/GenesisToolBox/frmRegisterStore.cs | 4 ++-- 3 files changed, 20 insertions(+), 8 deletions(-) diff --git a/Common/LaaPackages b/Common/LaaPackages index a9ef9051..41c1163d 160000 --- a/Common/LaaPackages +++ b/Common/LaaPackages @@ -1 +1 @@ -Subproject commit a9ef9051cabb74806a4ce0293794cf95756883e6 +Subproject commit 41c1163d102dbb63572e60c6ffd501e1765d848c diff --git a/Common/Ui/GenesisToolBox/FrmLowLevelTools.cs b/Common/Ui/GenesisToolBox/FrmLowLevelTools.cs index 14c14df9..9305beed 100644 --- a/Common/Ui/GenesisToolBox/FrmLowLevelTools.cs +++ b/Common/Ui/GenesisToolBox/FrmLowLevelTools.cs @@ -399,9 +399,21 @@ namespace Xylem.Common.Ui.GenesisToolBox }// Database returned valid passwords else { - // CASE 6: - The login succeeded but the password file request from database failed - LogText("Successfully logged in with the 'offline password'.\n" + - "Passwords cannot be acquired from the database and therefore not compared"); + + if (string.IsNullOrEmpty(_currentGenesis.OfflinePassword)) + { + // CASE 6: - The login succeeded but the password file request from database failed and no offline pwd + LogText("Successfully logged in with the 'production password'\n" + + "Passwords cannot be acquired from the database and therefore not compared"); + } + else + { + // CASE 7: - The login succeeded but the password file request from database failed and offlie pwd + LogText("Successfully logged in with the 'offline password'\n" + + "Passwords cannot be acquired from the database and therefore not compared"); + } + + } }// Initial login succeeded @@ -417,7 +429,7 @@ namespace Xylem.Common.Ui.GenesisToolBox Thread.Sleep(2000); // Try to log in with password level 8 which may not be published to the database var retVal = _currentGenesis.Login(Encoding.UTF8.GetString(pwdContainer.ListOfPasswords.Last())); - // CASE 6: - Passwords are generated in database and correctly installed. The login check will be done + // CASE 8: - Passwords are generated in database and correctly installed. The login check will be done // with the generated password, but the 'production password' is still the 'SkeletonKey'. // - The database update of the production password went wrong! if (_currentGenesis.IsLoggedOn && retVal) @@ -436,7 +448,7 @@ namespace Xylem.Common.Ui.GenesisToolBox { // This is needed from meter as an unsuccessful login requires a delay for the next trial Thread.Sleep(4000); - // CASE 7: - The production password didn't work, so the SkeletonKey will be tried. + // CASE 9: - The production password didn't work, so the SkeletonKey will be tried. if (_currentGenesis.Login(pwdContainer.Skeleton)) { ShowPasswordRepairMessage("Successfully logged in with 'SkeletonKey'\n" + diff --git a/Common/Ui/GenesisToolBox/frmRegisterStore.cs b/Common/Ui/GenesisToolBox/frmRegisterStore.cs index 20e884b7..ecc758cc 100644 --- a/Common/Ui/GenesisToolBox/frmRegisterStore.cs +++ b/Common/Ui/GenesisToolBox/frmRegisterStore.cs @@ -158,7 +158,7 @@ namespace Xylem.Common.Ui.GenesisToolBox if (!string.IsNullOrEmpty(cbComSlot.SelectedItem.ToString()) && int.TryParse(cbComSlot.SelectedItem.ToString(), out var slotNR)) { - //SetBusy(true, "Connect"); + SetBusy(true, "Connect"); if (Connect(slotNR)) { Task.Factory.StartNew(() => @@ -282,7 +282,7 @@ namespace Xylem.Common.Ui.GenesisToolBox } } - //SetBusy(false); + SetBusy(false); } }