I'm tired of doing the same thing over and again in vdubmod, so I tried to make a macro.
When the application opens, everything works fine. Msched presses F7 and the "Save As" window opens. Again everything is fine. But when msched pushes the "Configure" Button a new window opens. And then msched just stops.
Why is that?
Virtualdobmod: Msched stops by the 3rd window
Moderators: Dorian (MJT support), JRL
- Marcus Tettmar
- Site Admin
- Posts: 7393
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Are you using the PushButton command? If so try sending keystrokes to the button instead. E.g. use the ALT key shortcut, or Press TAB to it and Press Enter. Also make sure you are allowing time for the window to appear before trying to click the button. Use WaitWindowOpen etc.
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?
Done all that
It doesn't work. Msched just doesn't recognize the new window.
- Marcus Tettmar
- Site Admin
- Posts: 7393
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
I'm sure there is a way to get your macro to work. But without seeing your code and some screen shots we cannot really help further.
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?
The code
Here goes. As you can see, I've tried many things
--------------------------------------------
//Recorded Events
Input>navn,Navn på fil:,
Let>WW_TIMEOUT=5
Let>bitrate=1600
Let>kodek=DivX
CapsOff
SetFocus>VirtualDubMod*
Press F7
WaitWindowOpen>Save As*
SetFocus>Save As*
Press Alt
SEN>f
Release Alt
Send>1-
Send>navn
GetCheckBox>Save As*,Don't run this job now; add it to job control so I can run it in batch mode.,res
If>res=0
SetFocus>Save As*
MouseMoveRel>17,281
LClick
Endif
SetFocus>Save As*
MouseMoveRel>170,420
LClick
Press Home
Send>F
LClick
Wait>1
PushButton>Save As*,Change
Wait>1
// Let>MSG_STAYONTOP=0
// Let>MSG_XPOS=1
// GetActiveWindow>window_title,X,Y
// Message>window_title
// FindWindowWithText>Video codec information,1,res
//Message>res
//WaitWindowOpen>Select video compression
//SetFocus>Select video compression
//MouseMoveRel>100,100
//LClick
// Send>kodek
//LClick
Wait>1
//SetFocus>Select video compression
//MouseMoveRel>400,100
// LClick
// Press Alt
// Send>c
// Release Alt
--------------------------------------------
//Recorded Events
Input>navn,Navn på fil:,
Let>WW_TIMEOUT=5
Let>bitrate=1600
Let>kodek=DivX
CapsOff
SetFocus>VirtualDubMod*
Press F7
WaitWindowOpen>Save As*
SetFocus>Save As*
Press Alt
SEN>f
Release Alt
Send>1-
Send>navn
GetCheckBox>Save As*,Don't run this job now; add it to job control so I can run it in batch mode.,res
If>res=0
SetFocus>Save As*
MouseMoveRel>17,281
LClick
Endif
SetFocus>Save As*
MouseMoveRel>170,420
LClick
Press Home
Send>F
LClick
Wait>1
PushButton>Save As*,Change
Wait>1
// Let>MSG_STAYONTOP=0
// Let>MSG_XPOS=1
// GetActiveWindow>window_title,X,Y
// Message>window_title
// FindWindowWithText>Video codec information,1,res
//Message>res
//WaitWindowOpen>Select video compression
//SetFocus>Select video compression
//MouseMoveRel>100,100
//LClick
// Send>kodek
//LClick
Wait>1
//SetFocus>Select video compression
//MouseMoveRel>400,100
// LClick
// Press Alt
// Send>c
// Release Alt
- Marcus Tettmar
- Site Admin
- Posts: 7393
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
I downloaded VirtualDubMod. There's something funny about that Change button. And it doesn't have a short cut key sequence. That's open source for you
But pressing Tab to get to the Change button and then hitting Space works for me:
When the Save As window opens focus is in the filename box. So it's 9 tabs to get to the Change button.
I see you're doing other stuff on this form so you'll need to change the above code and you may need more or less tabs. But hopefully you get the idea.
Incidentally - why all the mouse events? I prefer to navigate around windows using the keyboard.
I suppose an alternative, since this is open source, is to fix it and add a short cut key (ALT key) to the Change button.
But pressing Tab to get to the Change button and then hitting Space works for me:
Code: Select all
SetFocus>VirtualDubMod 1.5.10.2*
Press F7
WaitWindowOpen>Save As
Wait>1
Press Tab * 9
Wait>1
Send>SPACE
WaitWindowOpen>Select video compression
MessageModal>done
I see you're doing other stuff on this form so you'll need to change the above code and you may need more or less tabs. But hopefully you get the idea.
Incidentally - why all the mouse events? I prefer to navigate around windows using the keyboard.
I suppose an alternative, since this is open source, is to fix it and add a short cut key (ALT key) to the Change button.
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?