Share this post

Link to post

Share on other sites

JLogan3o13 1,125

I'm not an expert with AutoIT, but I would think this would depend mainly upon the executable you're wanting to "add" to. If it is a commonly installed windows app (Notepad for example), that you expect to already be on the system, you could simply write the script to do what you want, and then call the executable. Something like:

$message = "Loading... "

SplashTextOn("Starting Application", $message, 500, 50)

For $x = 1 to 10

$message = $message & $x & " "

ControlSetText("Starting Application", "", "Static1", $message)

sleep(300)

Next

$var = Msgbox(262144+4, "Accept", "This application is only for company employees. Click Yes if you wish to continue or no to exit.")

If $var = 6 Then

Run( "Notepad" )

Else

Exit

EndIf

If, however, it is an executable you are delivering with the splash screen/msgbox, etc., you might try an open source wrapper utility such as QuickBFC. With that, you can launch your first executable, and then whenever the conditions are met, use it to call the second. QuickBFC (I know there are others, but it is what I use) will wrap both executables into a single .exe for you. Hope this helps.