Jump to content

Need help


Recommended Posts

I am trying to make a bot that closes something everytime it pops up. I have msgboxes in the bot and it only closes the thing after click something on the msgbox. I need help, so that the msgbox doesn't interfere and it closes that thing as soon as it is there. Thanks a bunch

Link to comment
Share on other sites

something like this?

While 1
    $Name = "Your_Window_Name_Here"
    WinWait($Name, "")
    WinActivate($Name, "")
    WinWaitActive($Name, "")
    Send("{Enter}") ; will send a enter button to the active window
    Sleep(1000)
    If WinExists($Name, "") Then
        WinClose($Name, "")
    EndIf
WEnd
Enjoy the complexity.Feel the power of simplicity.
Link to comment
Share on other sites

something like this?

While 1
    $Name = "Your_Window_Name_Here"
    WinWait($Name, "")
    WinActivate($Name, "")
    WinWaitActive($Name, "")
    Send("{Enter}") ; will send a enter button to the active window
    Sleep(1000)
    If WinExists($Name, "") Then
        WinClose($Name, "")
    EndIf
WEnd

Woah, I just tried again and the hotkey I used to stop it worked. I still need help. Am I doing something half right with the hotkey? Is that why it works about half of the time? Thanks for all of the help

Edited by the101dan
Link to comment
Share on other sites

1) autoit is single thread not multi thread,you can only do one thing at a time, 2) most people won't help with a childish prank script.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

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