Sign in to follow this  
Followers 0
Mixam

noobie question

35 posts in this topic

msgbox() pausing the script is driving me nuts. Is there a way for me to popup a message box that doesn't pause the script?

Only thing i have been able to think of is making myself a new gui message box. All I want is a popup box that has a message and can be closed when you have read the message. If only msgbox() had an option to not pause the scipt I would use that.

While I'm already asking a question, I might as well ask another. How do i get my gui to open to the tab i want? It has 4 tabs, and i want to be able to open it to a specific tab when it opens depending on what menu option i click in the toolbar menu. Like first tab is setup and 4th is about. So if i click setup in the menu i want the gui to open up to setup and if i click about I want it to open up to the about tab. Any help would be greatly appreciated

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

First Question: Make a script, and compile it as a .exe and run it :)

Second Question: Use: GUICtrlSetState($MyTab3, $GUI_FOCUS)

Edited by R6V2

Share this post


Link to post
Share on other sites

message boxes always seem to pause a script.

can you use a balloon tooltip instead?

ToolTip("This is a Message", 400, 400, "message", 0, 1)
sleep(4000)

Share this post


Link to post
Share on other sites

Thank you for your quick response. One more question while i'm here:

How do i get a txt file to open up in notepad ?? I could run notepad, but then don't know how to get it to load the file i want. There has to be an easy way to do this and i just can't find it. I've been searching the help file but I can't figure it out. I ran accros word.au3 but i just want it to open in notepad. I don't even have word...

Share this post


Link to post
Share on other sites

ShellExecute("notepad", $FileToOpen)

Share this post


Link to post
Share on other sites

message boxes always seem to pause a script.

can you use a balloon tooltip instead?

ToolTip("This is a Message", 400, 400, "message", 0, 1)
sleep(4000)
No i want the message to stay open till someone clicks ok or cancel or whatever. I though of tootip, or splashtoscreen, but both just stay open till sleep is over. I want it to stay open indefinately until it gets closed. However i don't want the script remaining paused during this time.

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

Global $sFile = "file.txt"
Run("notepad.exe " & $sFile)

EDIT: or you can use ShellExecute like R6V2 said.

Edited by cppman

Share this post


Link to post
Share on other sites

ShellExecute("notepad", $FileToOpen)
Thank you very much! I used ShellExecute("notepad", "readme.txt", @ScriptDir) and it worked :)

Share this post


Link to post
Share on other sites

Why not just use /AU3ExecuteLine?

Share this post


Link to post
Share on other sites

Why not just use /AU3ExecuteLine?

Maybe because that requires AutoIt?

Share this post


Link to post
Share on other sites

#11 ·  Posted (edited)

No it doesn't.

Edit: You don't have to have AutoIt installed.

Edited by JustinReno

Share this post


Link to post
Share on other sites

I guess you could write stand-alone scripts to call, that had msgboxs in them and nothing more. Then they would be running separately and it would not pause anything...

Seems kind of silly and cumbersome, but that's the best idea I've got...Because I suck.

Share this post


Link to post
Share on other sites

You could put it in the script itself.

Share this post


Link to post
Share on other sites

You could put it in the script itself.

Another useless remark. If he puts it in the script...It pauses the script.

Share this post


Link to post
Share on other sites

Your mind cannot comprehend the most basic things, can it?

Share this post


Link to post
Share on other sites

Your mind cannot comprehend the most basic things, can it?

My mind can comprehend, alot more than yours can. Yours just goes, in, and then out. Your problem is, that you never give enough information, so you leave room for alot of errors, and then when they're wrong, you insult them. I wonder why know one likes you? Dbak didn't, thats why he banned you. And im pretty sure, more people like me than you.

Share this post


Link to post
Share on other sites

I did not leave errors. Your mind did not comprehend what I said, your too young (Especially with that childish remark)

This is in the helpfile.

Run(@ScriptFullPath & ' /AutoIt3ExecuteLine "MsgBox(0, ''Hello World!'', ''Hi!'')"')

PS. I'm LS

Share this post


Link to post
Share on other sites

#19 ·  Posted (edited)

I did keep it on topic. Don't call me a kiddy. I'm not a software cracker.

Edited by JustinReno

Share this post


Link to post
Share on other sites

I did keep it on topic. Don't call me a kiddy. I'm not a software cracker.

Haha, you are a kiddie. I'm childish? Have you ever seen yourself post?

Share this post


Link to post
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
Sign in to follow this  
Followers 0