No Window Name available
Moderators: JRL, Dorian (MJT support)
Is your OS Windows 7?
Does your version of Macro Scheduler support RP_ADMIN?
If yes, try:
Let>RP_ADMIN=1
Run Program>C:\Program Files\XXcopy\xxcopy.exe Q:\*\* T:\Snap\ /CR8 /BU /PB /FF /CK0 /OAQ:\Data\Backups\Logs\20110824Msg.log /FoQ:\Data\Backups\Logs\20110824Files.log /FMSDTZAL /EXQ:\Data\Backups\Xxcopy\ExcludeList.txt
Does your version of Macro Scheduler support RP_ADMIN?
If yes, try:
Let>RP_ADMIN=1
Run Program>C:\Program Files\XXcopy\xxcopy.exe Q:\*\* T:\Snap\ /CR8 /BU /PB /FF /CK0 /OAQ:\Data\Backups\Logs\20110824Msg.log /FoQ:\Data\Backups\Logs\20110824Files.log /FMSDTZAL /EXQ:\Data\Backups\Xxcopy\ExcludeList.txt
Thanks for that suggestion, but cannot try for another day. Suspect it will not have an effect. It seems that this OS check is looking at the dates of the OS kernel and a user dll file. If later than compiled date of xxcopy then warning is triggered, and real xxcopy is not run yet.
Will let you know the results.....
Will let you know the results.....
- Bob Hansen
- Automation Wizard
- Posts: 2475
- Joined: Tue Sep 24, 2002 3:47 am
- Location: Salem, New Hampshire, US
- Contact:
I found the java script I had remembered, and did get to try it out. I don't recall where I got it from (RexCopy ?), but the original author's name is included in my script. Seems to be working, but it does come up with a message that XXCOPY is not running even though the window is open. When I close that error window, it seems to continue to work OK.
Here is the Macro Scheduler script:
When I ran this test, the SendKeys.js script was in the Rexcopy folder on Drive Q as noted in the script. I also added some lines so I could see the Progress Bar for quicker feedback about the running status.
Here is the SendKeys.js script:
This could be modified to remove the last "else" line so you don't get the message about XXCOPY not running. I don't recall that message coming up when I first used this a few years ago, and it may be related to your original comments about a ConsoleWindowClass in Windows7. I have no knowledge about those Microsoft objects, so I can't offer any help about that. But this seems to work. You can modify the times of 500 as you need the delays for your own use.
This java script is also a generic script, it can be used for any program, not just for Macro Scheduler. My original use with Macro Scheduler was in a batch file on some XP systems. You may also want to look at RexCopy, it is a GUI interface for XXCopy so you don't need to keep looking all of the switches. I don't use RexCopy, I am old school and prefer to select the codes myself. See more here: http://rexcopy.diorama.ch/
I would also try out the last suggestion from armsys about using MouseMove/LClick/Press Enter. That looks good to me also.
Here is the Macro Scheduler script:
Code: Select all
SRT>TestOne
Let>RP_WINDOWMODE=1
Run Program>C:\Program Files\XXcopy\xxcopy.exe M:\*\* T:\98\C /CR8 /BU /PB /FF /WV0 /CK0 /OAM:\Data\Backups\Logs\20110831Msg.log /FoM:\Data\Backups\Logs\20110831Files.log /FMSDTZAL /EXM:\Data\Backups\Xxcopy\ExcludeList.txt
Wait>20
ChangeDirectory>Q:\Masters\Xxcopy\Rexcopy
Run Program>wscript SendKeys.js xxcopy ~
Wait>10
WaitWindowOpen>Progress - XXCOPY*
WaitWindowClosed>Progress - XXCOPY*
Let>RP_WINDOWMODE=0
End>TestOne
Here is the SendKeys.js script:
Code: Select all
//SendKeys.js
// Original Script by Urs Eberle, 2008 public domain
// Modified Script by Bob Hansen, 2009 public domain
// This script will send keyboard keys to a running program.
// Two arguments are needed:
// The windows title of the program and the key(s) to be sent
// The script will wait for 500 ms before the key is sent in order to give the program
// The time to load if it is started together with the script or immediately after.
// Example1: SendKeys.js calculator 100
// will enter the figure 100 into the windows calculator (which must be running).
// Example2: SendKeys.js xxcopy ~
// will enter the "~" character into the xxcopy window (which must be running).
// The tilde character "~" acts as an Enter key.
// For the special keys syntax consult the 'Microsoft Windows Script //Technologies' manual.
var WshShell = new ActiveXObject("WScript.Shell");
var objArgs = WScript.Arguments;
if (objArgs.length < 2)
{ WScript.Echo("This script must be run with two arguments!");
WScript.Quit();
}
// WScript.Sleep(500); // delete this if the program has been started before the script
if (WshShell.AppActivate(objArgs(0)) == true)
{ WScript.Sleep(500);
WshShell.SendKeys (objArgs(1));
}
else WScript.Echo("Program '"+objArgs(0)+"' is not running!");
This java script is also a generic script, it can be used for any program, not just for Macro Scheduler. My original use with Macro Scheduler was in a batch file on some XP systems. You may also want to look at RexCopy, it is a GUI interface for XXCopy so you don't need to keep looking all of the switches. I don't use RexCopy, I am old school and prefer to select the codes myself. See more here: http://rexcopy.diorama.ch/
I would also try out the last suggestion from armsys about using MouseMove/LClick/Press Enter. That looks good to me also.
Hope this was helpful..................good luck,
Bob
A humble man and PROUD of it!
Bob
A humble man and PROUD of it!
- Bob Hansen
- Automation Wizard
- Posts: 2475
- Joined: Tue Sep 24, 2002 3:47 am
- Location: Salem, New Hampshire, US
- Contact:
Hi Armsys.
I was alerted to this item and was asked to consider providing some input. I am still distracted right now, and will probably disappear again once we have this item fixed.
If my memory is correct, I believe you also took a long leave of absence some years ago. Glad to see you are still here with your help.
I was alerted to this item and was asked to consider providing some input. I am still distracted right now, and will probably disappear again once we have this item fixed.
If my memory is correct, I believe you also took a long leave of absence some years ago. Glad to see you are still here with your help.
Hope this was helpful..................good luck,
Bob
A humble man and PROUD of it!
Bob
A humble man and PROUD of it!