Jump to content

Splash problems


Recommended Posts

I use splash screen as part of a picture viewer. I like to keep my controls on top of the splash screen. It used to work, but the lastest version has broken my code. Below is an example code to show my problem. The first 2 times my controls stay on top as they should. The next two times and forever after the controls get hidden by the splash screen. How do I get around this and keep my controls on top?

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <ButtonConstants.au3>

$destination = "C:\Users\Public\Pictures\webpic\100_3707.jpg" ;Use whatever pic you have handy


GUICreate("My GUI", 150, 80,850,600,$WS_EX_OVERLAPPEDWINDOW,$WS_EX_TOPMOST)  
GUISetState (@SW_SHOW)       ; will display an empty dialog box
$count=0
While $count<4
    SplashImageOn("Splash Screen", $destination,@DesktopWidth, @DesktopHeight,0,0,3)
    Sleep(1000)
    SplashOff()   
    $count=$count+1
WEnd
Link to comment
Share on other sites

I don't know why you see that behavior in the first place, but this works around it:

$hGui = GUICreate("My GUI", 150, 80,850,600,$WS_EX_OVERLAPPEDWINDOW,$WS_EX_TOPMOST)
GUISetState (@SW_SHOW)       ; will display an empty dialog box
$count=0
While $count<4
    SplashImageOn("Splash Screen", $destination,@DesktopWidth, @DesktopHeight,0,0,3)
    WinSetOnTop($hGui, "", 1)
    Sleep(2000)
    SplashOff()
    $count=$count+1
WEnd

:unsure:

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...