I would like to show a not interactive screen to inform the user of loading data before the actual interactive screen is shown.
Currently I am using the engine.ShowProress method before creating + showing the actual interactive dialog. Although it works fine for the purpose, it is not possible to give the loading screen a proper title. It will show the automation script name.
How can I show a default screen with a nice "loading" title without blocking any of the code ( = not waiting for any user input)
Hi Mieke,
I have something similar in which I grey out all the UI Fields and push updates about the progress to a TextBox.
To do this I used the "RequestManualMode" method on the InteractiveController object.
This is a small example of the code:
private readonly InteractiveController controller;
private void Confirm_Pressed(object sender, EventArgs e)
{controller.RequestManualMode(
() =>
{
StatusTextBox.IsVisible = true;
DisableAllUiFields();
ProgressUpdate($"Prepping action …");
// Do something
});
}private void ProgressUpdate(string progressString)
{
StatusTextBox.Text += $"\n[{DateTime.Now.ToLocalTime()}] {progressString}";
Show(false);Engine.GenerateInformation(progressString);
}
I think with this you should be able to create and show a proper loading screen.
Thank you, I’ll have a look.
Do note that I do not have a button that starts the logic.
The Script is triggered from a dashboard and the first thing it needs to to is collect info = the loading part.
After this I’m showing a dialog with buttons.
So I’m really looking for a means to show a screen without any buttons at all.
As of the latest publicly released NuGet versions of the toolkit, it is no longer needed to use controller.RequestManualMode to implement such functionality.
You can now execute your long-running method directly in the button event handler.