Jump to content

WinWait doesn't wait (The sample doesn't work) please help


Go to solution Solved by ywangperl,

Recommended Posts

I'm done.  Can't get enough information from you to help.  I can only infer that you are running the script through a command prompt, but you will not give a valid answer.

Good luck.

IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.
Link to post
Share on other sites

I find the cause and I am looking for a solution.

WinWaitActive is a asynchronis event.  It spawn a process in the background for "timeout" seconds while user can type dos>command.

I was hoping that WinWaitActive can "wait" and hold the dos> for accepting other command.

-Y

Link to post
Share on other sites

Ok, first, the word right above someone's icon (seeker, in your case) is not their userID. The word above that is their userID. When addressing a post to a particular person, their actual userID should be used.

Now, back to your issue. If I run the following code from the DOS prompt, all that happens, and all that should happen, is Notepad gets started up. ConsoleWrite is a function that outputs to SciTE's console, not to the screen in general. In your testing code, use the MsgBox function instead of ConsoleWrite. Refer to the Help file, as those two functions take a different syntax of parameters.

Run("notepad.exe")
Local $sString = "running autoIt"
ConsoleWrite($sString & @CRLF)
$hwnd = WinWait("[CLASS:Notepad]")
Consolewrite($hwnd & @crlf)

"c:\Program Files (x86)\AutoIt3\AutoIt3.exe" ex0415c.au3

- Bruce /*somdcomputerguy */  If you change the way you look at things, the things you look at change.

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
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...