Jump to content


xc3ss1v3

Skipping Task Sequence Step

Recommended Posts

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.

Share this post


Link to post
Share on other sites

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

Share this post


Link to post
Share on other sites

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.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...


×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.