Search found 57 matches

by kriemer
Thu Mar 24, 2011 4:02 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

After a dozen consecutive runs with no failures (I hate saying that as it is typically the tipping point where things go wrong), I can say I'm happy with the working of the script. Hopefully I won't have to come back with a new request for help. I don't think it is the MS path string limit (255 char...
by kriemer
Wed Mar 23, 2011 5:12 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

I don't know how I lost it in the code I copied but I have a wait statement just before the "//"Kill" RunProject.exe" portion of the script. I apologize for this error and wasting peoples time on the code which was not accurate. Correct code follows: //Variables Let>loopcounter=-1 GetDate>vToday Let...
by kriemer
Wed Mar 23, 2011 1:25 am
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

I have added the "TestForProcessComplete" script snippet right after the repeat loopcounter line. I no longer think it is necessary, but it is nice to be sure that RunProject is close, and it is way more efficient than a simple "Wait>n" statement. I now have a new idea where my problem really lies. ...
by kriemer
Tue Mar 22, 2011 8:47 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

I've only added a "WAIT>10" after the "Repeat>LoopCounter". My logic is that after the script completes: 1 - "wait>RunTimeSec" -times out starting 2 - //"Kill" RunProject.exe VBSTART set wmi = getobject("winmgmts:") sQuery = "select * from win32_process where name = 'RunProject.exe'" set processes =...
by kriemer
Tue Mar 22, 2011 7:41 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

I'm really confused. The processes all close, before the script loops around for the test phase. But the last loop of the script will more often than not incorrectly show some number of files as missing. The good news is that it is not the logic of my script. I can be comfortable with that at least....
by kriemer
Tue Mar 22, 2011 6:56 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

Yes the process does stay open. It appears I am struggling against two competing requirements. 1 - The script to continue and reloop at the end of the "runtimesec" count 2- The script to wait for the processes to close before running the test portion of the script. As I write this I think the answer...
by kriemer
Tue Mar 22, 2011 6:37 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

The "Label>TestForProcessComplete" works as advertised. Many Thanks My problem is now getting "wait>RunTimeSec" to be able to timeout and restart the loop. Sometimes the individual RunProjects need to be restarted, they appear to enter some sort of stupid state which is why I have built the script t...
by kriemer
Tue Mar 22, 2011 4:54 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

I need all the "run>"C:\Program Files\VWR\RunProject.exe" "%Path%\Projects\XXX.rip" routines to run concurrently, then wait, then run the Test to complete. "Let>RP_WAIT" waits for each section of the script to complete then allows the next run to start, etc. I tried putting "Let>RP_WAIT=1" before th...
by kriemer
Tue Mar 22, 2011 4:06 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

No I don't. I didn't think it necessary as the files are created (and the "Let>runtimehour=n" leaves a long time after programs end before the loop goes around to tests), but I will add and report back.

Thanks

k
by kriemer
Tue Mar 22, 2011 3:45 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

First the files are deleted (from previous runs): //Delete VWR Output Files DeleteFile>%Path%\Output\R*.* DeleteFile>%Path%\Output\Y*.* DeleteFile>%Path%\Output\Interactive*.* Wait>10 Later this section creates the files: //Test & Run VWR Scrapes IfFileExists>%Path%\Output\R_Estimates_a\R_Estimates_...
by kriemer
Tue Mar 22, 2011 2:09 pm
Forum: Technical / Scripting
Topic: Looping Test - Works Sometimes
Replies: 17
Views: 17937

Looping Test - Works Sometimes

The script below is only a partial of the entire script; missing are another 6 test and run sections. The "//Test If Files Exist" portion of the script works but randomly. I can run the script and all of the routines properly execute, files are saved in the proper locations but on completion the mes...
by kriemer
Mon Mar 21, 2011 9:56 am
Forum: Technical / Scripting
Topic: Time Calculation in MessageBox
Replies: 2
Views: 4203

So simple, once you know; so hard to know.

Thanks for the answer this was really starting to bug me.

k
by kriemer
Sun Mar 20, 2011 4:32 pm
Forum: Technical / Scripting
Topic: Time Calculation in MessageBox
Replies: 2
Views: 4203

Time Calculation in MessageBox

I use the following partial code //Set RunTime in Hours Let>RuntimeHr=0.03 Let>RunTimeMin=RunTimeHr*60 Let>RunTimeSec=RunTimeMin*60 //Time Calculation & Screen Message Box - All Attempts VBEval>DateAdd("m",%RunTimeHr%,now),LoopEndTime Let>MSG_STAYONTOP=1 Message>Loop Run Time: %RunTimeHr% Hour(s) / ...
by kriemer
Wed Jul 21, 2010 12:44 am
Forum: Technical / Scripting
Topic: Find oldest file in directory & run script
Replies: 3
Views: 7465

I found/modified the following VBS script to finds the oldest file in a directory of a particular extension. The date stamp of the file is stored in a variable datMax. I need to execute the last line of the script with the datMax variable. Problem is it doesn't work. What am I doing wrong or is this...
by kriemer
Wed Feb 24, 2010 2:42 am
Forum: Technical / Scripting
Topic: Excel Macros
Replies: 4
Views: 5854

I'm curious why you would not want to get rid of the nag.

I've had the same issue, and my solution was a registry mod to get past the window, but if I am doing something wrong or ill advised I'd like to know.

Thanks

k
Sign up to our newsletter for free automation tips, tricks & discounts