Hi:
I downloaded your trail software about a year ago ... and never finished my project... I wanted to finish it - and re-downloaded the trail version. But the parts of the scrip which where working back then are not working anymore ...?
The "WaitWindowOpen>Microsoft Excel" is just hanging.
Here is the sample code... I got rid of the rest for now (it is displaing "test1" but not "test2")
MouseMove>0,0
Let>delay=1
Let>ExcelWaitTime=0.05
Let>filename=%SCRIPT_DIR%\test.xls
IfFileExists>filename
ExecuteFile>filename
MessageModal>test1
WaitWindowOpen>Microsoft Excel -*
MessageModal>test2
Send>**********START******************************
Press Enter * 1
Wait>ExcelWaitTime
Label>end_script
Any help would be highly appreciated.
Thanks,
Susanne
"WaitWindowOpen>Microsoft Excel" is hanging
Moderators: Dorian (MJT support), JRL
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Works ok for me, although you have an Endif missing. My script is:
This works for me. But which version of MS Excel do you have?
WaitWindowOpen doesn't "hang". As it's name suggests it *waits* until the window specified opens. If that window never opens or is never found, then WaitWindowOpen will wait forever. So if it appears to be "hanging" this means that the window title specified is not being found.
Which version of Excel do you have? Also are you running the latest version of Macro Scheduler (9.1)?
BTW - one problem with your script is that after Excel opens you then have the line MessageModal>test2. This will cause focus to be removed from Excel and back to Macro Scheduler. Therefore the subsequent Send and Press Enter commands will cause keystrokes to land on Macro Scheduler. Either remove the MessageModal line or insert a SetFocus line after it to ensure Excel is focused for the keystrokes.
Code: Select all
MouseMove>0,0
Let>delay=1
Let>ExcelWaitTime=0.05
Let>filename=%SCRIPT_DIR%\test.xls
IfFileExists>filename
ExecuteFile>filename
MessageModal>test1
WaitWindowOpen>Microsoft Excel -*
MessageModal>test2
Send>**********START******************************
Press Enter * 1
Wait>ExcelWaitTime
Endif
Label>end_script
WaitWindowOpen doesn't "hang". As it's name suggests it *waits* until the window specified opens. If that window never opens or is never found, then WaitWindowOpen will wait forever. So if it appears to be "hanging" this means that the window title specified is not being found.
Which version of Excel do you have? Also are you running the latest version of Macro Scheduler (9.1)?
BTW - one problem with your script is that after Excel opens you then have the line MessageModal>test2. This will cause focus to be removed from Excel and back to Macro Scheduler. Therefore the subsequent Send and Press Enter commands will cause keystrokes to land on Macro Scheduler. Either remove the MessageModal line or insert a SetFocus line after it to ensure Excel is focused for the keystrokes.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
Thanks for your fast response!
The excel file is opening fine - but then the sript is just "hanging"
... that's why I tried to add Message-2 to see where it is "hanging"...
I have MS Excel 2003 (11.8120.8122) SP2.
Macro Scheduler: Version 9.0.054e (eval) / April 2007
I tied your script ... but the same result...
Thanks,
Susanne
The excel file is opening fine - but then the sript is just "hanging"
... that's why I tried to add Message-2 to see where it is "hanging"...
I have MS Excel 2003 (11.8120.8122) SP2.
Macro Scheduler: Version 9.0.054e (eval) / April 2007
I tied your script ... but the same result...
Thanks,
Susanne
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Run this:
Run the script, wait 10 seconds for the message window - do not click the mouse or press any keys in this time. Tell us what the message is in the message window.
Code: Select all
MouseMove>0,0
Let>delay=1
Let>ExcelWaitTime=0.05
Let>filename=%SCRIPT_DIR%\test.xls
IfFileExists>filename
ExecuteFile>filename
Wait>10
GetActiveWindow>title,X,Y
MessageModal>title
Endif
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Ok, so your script needs to be:
Code: Select all
MouseMove>0,0
Let>delay=1
Let>ExcelWaitTime=0.05
Let>filename=%SCRIPT_DIR%\test.xls
IfFileExists>filename
ExecuteFile>filename
MessageModal>test1
WaitWindowOpen>Microsoft Excel*
MessageModal>test2
SetFocus>Microsoft Excel*
Send>**********START******************************
Press Enter * 1
Wait>ExcelWaitTime
Endif
Label>end_script
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
THANKS !!!
Thanks a Lot,
that's it!
Susanne
that's it!
Susanne