Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


StuartS
2010-02-08T11:25:39Z
I've set up a job containing several tasks, which basically should:

A inactivate all other VC jobs
B run a program (which takes about 2 mins to complete)
C activate all other VC jobs

It seems that all 3 start simultaneously: parts A and B run ok, but C also starts before B has finished. I set a condition that C should not start if B is still running, but this is ignored.

I've set "run tasks in order" on the main job.

VC 5.4.7 on Windows XP SP2.
Sponsor
Forum information
Support
2010-02-08T11:29:17Z
Job control Tasks are running as new instances and "forked" off which means they leave the current Task flow when being executed. When a "Jog control" Task has successfully started it goes on to the next Task (it does not wait for completion because it is forked off).

But, why are you inactivating and activating Jobs? Seems like there must be a better solution to what you are doing.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
StuartS
2010-02-08T11:44:44Z
Hi Henrik

I live in an area with frequent lengthy power cuts, and the UPS only last for about 15 minutes. Therefore, on restart, I don't want any of the usual tasks to run before the "clean-up" program has checked the system for old/corrupt files. When it has finsihed, then I want the usual tasks to be activated.

Of course, I could create a startup batch file which runs this program and then starts VC services, but that doesn't seem very elegant.

I checked the flowchart for this task, and all the job dependencies were correct, i.e. running one after another. I therefore don't understand what you meant in your last post.

Let me put it another way - is there a way to do what I want in VC?

Regards

Stuart
Support
2010-02-08T11:55:36Z
I see. To put it in short, Jobs or Tasks that are execute through the Job Control Task, are "out of normal Task flow".

One way to solve this is to create a file in a Task triggered by System startup. Then delete the file when you are done with check. On all other Jobs you can use a Condition to check if that file exists or not.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
StuartS
2010-02-08T12:18:31Z
Hi Henrik

That doesn't seem very elegant, and means changing/re-testing all the VC job entries.

My other idea, was to:

- permanently set VCron service to "Manual" startup, instead of "Automatic" in the Microsoft Service Controller.

- create a batch file to run the clean-up program on startup

- when it's finished start VCron service using the "SC" command

Would this work? Then it would solve this problem, and the system restart trigger problem.

Regards

Stuart
Support
2010-02-08T12:27:07Z
I did not say my solution was elegant. You can use your solution but then you got dependencies on the startup command as well.

What you may want is a Task stopping the VC server (not service) which inactivates all Jobs and then perform your Task and then activate all again. Perhaps something to add as a feature request.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Scroll to Top