Splash Screen? #6026
-
|
Hi all, I'm trying to implement a splashscreen in my app as there's a fair bit of time pulling data from a database on startup. This isn't super well documented and the two github issues I could find are from before the Application Lifetime code was changed. #2674 #4155 Here's my Program.cs Splash Window View Model: Splash Window: I see the app running in the Taskbar once the splash.Show() is called (albeit with no icon - just an empty square). Mousing over it, it has the correct window title from my SplashWindow but the window thumbnail is black/empty. The SplashWindow does not display. If I remove the line splash.Close();, then the SplashWIndow appears at the same time as the MainWindow. Am I on the right track with this or is there a better way to do this? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
OK - Ignore this - it turns out this code is working just fine. Adding await Task.Delay(1); directly after splash.Show() causes the splash screen to show much quicker! |
Beta Was this translation helpful? Give feedback.
OK - Ignore this - it turns out this code is working just fine. Adding await Task.Delay(1); directly after splash.Show() causes the splash screen to show much quicker!