Adding error trap so that the display prompts can be bypassed if it doesn't work, will still try to set the date and time.

This commit is contained in:
2025-01-07 15:49:51 +00:00
parent e7e216597a
commit a81318f4b5
+17 -10
View File
@@ -686,19 +686,26 @@ namespace ASCOM.Meade.net
}
default:
{
var i = 10;
while (i > 0)
try
{
var displayText = Action("Handbox", "readdisplay");
if (displayText.Contains("Align:"))
var i = 10;
while (i > 0)
{
i = 0;
continue;
}
var displayText = Action("Handbox", "readdisplay");
if (displayText.Contains("Align:"))
{
i = 0;
continue;
}
Action("Handbox", "mode");
_utilities.WaitForMilliseconds(500);
i--;
Action("Handbox", "mode");
_utilities.WaitForMilliseconds(500);
i--;
}
}
catch (TimeoutException e)
{
LogMessage("ApplySkipAutoStarPrompts","Timed out bypassing the date time prompts. Skipping.");
}
break;