Jump to content

I need a little more assistance with this while loop


Recommended Posts

Could some one be so kind and connect with me remotely to get this code to work below for me? I'm using a remote connection app called"Teamview" ,I'll send you the app. I just need a little more assistance and someones eyes on my screen as my eyes are on my screen. My functions aren't executing.

While 1

    If WinWait("HyperVRE", "10 keyword selected") Then
        script_2()
    EndIf

    If WinWait("HyperVRE", "0 keyword selected") Or WinWait("HyperVRE", "1 keyword selected") Then
        script_1b()
    EndIf

    Sleep(100); save CPU

WEnd

; Functions-----------
; 

Func script_2()
;   --------------------------------------------------------------------------
;                                                  This is Script 2

code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here  
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 

EndFunc;==>script_2

Func script_1b()
;   ---------------------------------------------------------------------------
;                                                        This is Script 1b

code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here 
code will be here
EndFunc;==>script_1b
Edited by styles3000
Link to comment
Share on other sites

Opt("WinTextMatchMode", 1)     ;1=complete, 2=quick
Opt("WinTitleMatchMode", 3)     ;1=start, 2=subStr, 3=exact, 4=advanced, -1 to -4=Nocase


While 1

    If WinExists("HyperVRE", "10 keyword selected") Then
        script_2()
    EndIf

    If WinExists("HyperVRE", "0 keyword selected") Or WinExists("HyperVRE", "1 keyword selected") Then
        script_1b()
    EndIf

    Sleep(10); save CPU
WEnd




Func script_2()
    MsgBox(4096, "", "Script 2")                                       
EndFunc;==>script_2

Func script_1b()
    MsgBox(4096, "", "Script 1b") 
EndFunc;==>script_1b

There is always a butthead in the crowd, no matter how hard one tries to keep them out.......Volly

Link to comment
Share on other sites

Opt("WinTextMatchMode", 1)     ;1=complete, 2=quick
Opt("WinTitleMatchMode", 3)     ;1=start, 2=subStr, 3=exact, 4=advanced, -1 to -4=Nocase


While 1

    If WinExists("HyperVRE", "10 keyword selected") Then
        script_2()
    EndIf

    If WinExists("HyperVRE", "0 keyword selected") Or WinExists("HyperVRE", "1 keyword selected") Then
        script_1b()
    EndIf

    Sleep(10); save CPU
WEnd




Func script_2()
    MsgBox(4096, "", "Script 2")                                       
EndFunc;==>script_2

Func script_1b()
    MsgBox(4096, "", "Script 1b") 
EndFunc;==>script_1b

Man, that looks familiar too.... :)

8)

NEWHeader1.png

Link to comment
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
 Share

  • Recently Browsing   0 members

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