Sign in to follow this  
Followers 0
Hoth2001

MsgBox to Intentionally Halt Program

3 posts in this topic

Hello All,

 

I want to intentionally cause a pause in the execution of my code.

I would like to execute a msgbox with an "OK" button which while open, halts the program.

Once the "OK" button is pressed, the code continues.

Not exactly sure how that syntax would work though.

Please help me insert the MsgBox in the below code:


 

Local $oExcel_2 = _Excel_Open()
    Local $sWorkbook2 = "C:\Users\User\Desktop\Planet Sheet.xls"
    Local $oWorkbook2 = _Excel_BookOpen($oExcel_2,$sWorkbook2)
    Sleep(1000)

_Excel_RangeWrite ($oWorkbook2, Default, $oTopCycle, "F7")
Sleep(300)
_Excel_RangeWrite ($oWorkbook2, Default, $oTopCycle, "F15")
Sleep(300)

;I WANT TO ENTER IN A PROMPT HERE TO HALT THE PROGRAM UNTIL I CLICK "OK" AND THEN CONTINUE WITH REST OF CODE AFTERWARDS
    
;VENUS FILTER

_Excel_FilterSet($oWorkbook2, Default, "A26:K37", 1, ">", 1, "<40")

 

Thanks!

Share this post


Link to post
Share on other sites



Look up the MsgBox function in your help file.

Share this post


Link to post
Share on other sites
5 hours ago, Danp2 said:

Look up the MsgBox function in your help file.

umm...right. duh.  Didn't realize that it did that too.

Newbie here....patience everyone

 

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