open windows

Recommended Posts

Queener 1

Queener 1

I notice that you can check and see if window exist, but how do you put a permanent check to see if the window close? If it close then re-open. Say for example, I use teamviewer and once in awhile it closes the connection on me if I'm idle for certain amount of time. I want it to automatic open a new session with the id and pw I provided if teamviewer close.

Msgbox(0, "Hate", "Just hate it when I post a question and find my own answer after a couple tries. But if I don't post the question, I can't seem to resolve it at all.")

Share this post

Link to post

Share on other sites

czardas 1,116

czardas 1,116

czardas - tested your code, but it doesn't open notepad when it's closed. I removed the ";" before consolewrite code,

Sorry. It worked on my machine. It was a quick example to which I didn't give much thought. Firefox's example is much better anyway. The method I used is taken from the helpfile tutorial, so I am now a little confused why it worked on my computer and not on yours. The helpfile tutorial gives this code:

;

Run("notepad.exe")WinWaitActive("Untitled - Notepad"); This is the syntax which fooled meSend("This is some text.")

;

Please could someone confirm that my >earlier example is broken, because it works perfectly for me.

Edit

I think this has to do with language settings - and the helpfile may need amending.