hiteksoftware.com Forum Index hiteksoftware.com
User discussion forum
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Task Sequence based on Variable Value

 
Post new topic   Reply to topic    hiteksoftware.com Forum Index -> Task Sequences, Chains and Scripts
View previous topic :: View next topic  
Author Message
melvin
Site Admin


Joined: 25 May 2006
Posts: 635
Location: Santa Barbara, california

PostPosted: Tue Oct 01, 2013 7:44 pm    Post subject: Task Sequence based on Variable Value Reply with quote

User Support Request:

I am trying to create a file move file task and if the task completes with error code = 0 then send a success email but if the job fails to I need it to send a failure email.

I created all the steps and run the task and it will move the file and email the success email no problem.

I remove the file from the source directory and the task still completes with error code = 0 when there is no file in the source directory to move.

Why does this not error when there is no file to move?
I need to know that the file exist and that It move the new copy everyday.
Back to top
View user's profile Send private message Send e-mail
melvin
Site Admin


Joined: 25 May 2006
Posts: 635
Location: Santa Barbara, california

PostPosted: Tue Oct 01, 2013 7:46 pm    Post subject: Reply with quote

Having 0 files is not an error condition.
You could check the variable value and send the emails based on the variable value.

Create 2 variable monitor tasks:

monitorCopied:
variable name = MoveToDrive::FilesCopied
variable value > 0
Task to run = MoveSuccessEmail

monitorNoFileExists:
variable name = MoveToGDrive::FilesCopied
variable value = 0
Task to run = MoveFailedEmail


Then in your task sequence:
step 1 = MoveToDrive
step 2 = monitorCopied
step 3 = monitorNoFileExists
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    hiteksoftware.com Forum Index -> Task Sequences, Chains and Scripts All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group