xc3ss1v3 Posted August 28, 2014 Report post Posted August 28, 2014 Hello all... Is there a way to skip a TS step based on whether or not a previous step ran? I've got some sequences that seek out various versions of software for uninstallation, restart the machine, then install the more recent version. The restart is essentially an unneeded step if the software doesn't exist on the machine in the first place. So, I was curious if there is a way that I can set the Restart step to only run if step 1, 2, or 3, ran. Thanks in advance. Quote Share this post Link to post Share on other sites More sharing options...
Jorgen Nilsson Posted August 28, 2014 Report post Posted August 28, 2014 Hi, You could either use _SMSTSLastActionRetCode, Which stores the return code that was returned by the last action that was run. This variable can be used as a condition to determine if the next step is run. Or you could do the evaluation if something is installed on a group instead and in the group exectue the uninstall command and then use the Set Task Seqeunce variable and create a custom variable which you check for later in the TS, or put the reboot in the group as well if that could be an option. Regards,Jörgen Quote Share this post Link to post Share on other sites More sharing options...
xc3ss1v3 Posted September 10, 2014 Report post Posted September 10, 2014 Hi, You could either use _SMSTSLastActionRetCode, Which stores the return code that was returned by the last action that was run. This variable can be used as a condition to determine if the next step is run. Or you could do the evaluation if something is installed on a group instead and in the group exectue the uninstall command and then use the Set Task Seqeunce variable and create a custom variable which you check for later in the TS, or put the reboot in the group as well if that could be an option. Regards, Jörgen Thanks Jorgen... Just as an FYI for anyone else that comes across this thread with similar questions, I used the _SMSTSLastActionSucceeded variable which stores (in a true or false string) whether or not the last action that ran was successful. The advantage to this variable is that it maintains the same string as long as the steps followed are skipped. In the case of un-installing multiple versions of software, this worked perfectly. Quote Share this post Link to post Share on other sites More sharing options...