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


Lynchie
2013-10-03T13:38:16Z
Afternoon All,

I spoke to Henrik about this briefly but wondering if anyone can shed light on something I'm doing to either say do it this way or has a solution to this they thought wouldn't need sharing.

I have 3 Tasks that run to enable me to post out Statements to various Clients. We get several of these everyday and trying to copy and paste and then change the DirectID references for the Tasks in each job is laborious at best.

Here is the Job.

UserPostedImage

The red is the client name and the blue is the client address separated by a tilde ~.

Task 2 and uses a 'PreviousTask' to pickup all the information that is decided via the Task 1 SQL query.

The Task 2 Powershell Script does not output anything instead it downloads from SSRS an excel file and saves it to a DIR again all decided dynamically by the Task 1 SQL Query Output.

I wish to use the same information from the Task 1 Output in Task 3 but obviously cannot reference it because Task 2 is the previous task and does not output the information.

I wish to do this so that I do not spend 15 minutes per client setting the Task Direct ID's when instead I can just change the 6 numbers in the WHERE statement of my SQL query and the rest is done dynamically via Visual Cron.

Basically I'm looking for some 'Previous Previous' Task functionality or workaround.

I have had 'Set Variable' mentioned to me but I don't even know where to begin.

Any ideas?

Cheers.
Sponsor
Forum information
Support
2013-10-03T19:31:31Z
Here is the workaround I suggested.

1. Create a Set Variable Task after the first Task ("Get Broker.."). In that Task you could use a user Variable with key name "PrevPrevTask". The value that you set could either be a specific value (like output or the id).

If you want to use the output for example you can use the value: {TASK(PrevTask,StdOut)}
Use "Translate to constant" option in the Set Variable Task.

2. now, in the third Task you can now use Variable: {USERVAR(PrevPrevTask)} to get the output of first Task.

This is just one example of how to so this.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Scroll to Top