0

I'm trying to set a "Reminder Date" field in a task list to 3 days prior to the Due date. Unfortunately, I need to use SharePoint Designer's workflow designer. I have the following workflow so far, but it has two problems:

  • The condition check always fails. I've read this is the best way to check if a date field is null, is that not the case?
  • If I remove the condition just to see if any update will work, the "Reminder Date" column always gets 1/1/1900 in it.

(Both the workflow and the update dialog are shown)

enter image description here

UPDATE: After some more debugging, it looks like CurrentItem:Due Date is always empty, even though I'm setting it while testing and the workflow is set to run on item creation. Any idea why that might be?

1
  • I also have the exact same problem. It seems that a calculated field will work, but in my case that defeats the whole purpose, as I am creating a reuseable workflow for Task content type. Have anyone solved this?
    – user34375
    Oct 17, 2014 at 5:26

3 Answers 3

1

I had the same requirement. I solved it by writing the condition as "if less than 1/1/1900 12:00:00 AM". Here is a screenshot from my workflow.

enter image description here

5
  • Thanks, this worked for the date comparison. However the other problem remains. I added new details in the OP.
    – MgSam
    Jul 30, 2014 at 19:05
  • So if you enter a date in the "Due Date" column and just log that column "CurrentItem:Due Date" to the workflow history its blank? Can you log other columns to the workflow history? Jul 30, 2014 at 19:23
  • It logs it as "Monday, Jan 1, 0001", which I believe is the string representation of a blank date field.
    – MgSam
    Jul 30, 2014 at 19:33
  • I've never heard of any behavior like that. Just to confirm, the Due Date is entered when you complete the standard New Item Form (newform.aspx)? Jul 30, 2014 at 19:57
  • Yes, that's correct.
    – MgSam
    Jul 30, 2014 at 21:57
0

Have you tried using a calculated field instead of a workflow for this?

=[Due Date] - 3
1
  • I considered that, but then the user cannot override it. This is supposed to only take effect if the user inputs nothing in "Reminder Date".
    – MgSam
    Jul 29, 2014 at 19:27
0

I would consider using a 2010 workflow such as:

Add -3 days to Current Item:Due Date (Output to Variable:Reminder Date) Log Variable:Reminder Date to the workflow history list Pause until Variable:Reminder Date Then Email Then stop the workflow and log Reminder Email Sent

The extra log will allow you to double check that current item due date comes in properly and that the math is done correctly. You should be able to start this on creation and edit. Since it is a workflow variable they will then recalculate if the date is edited. If you find that the date doesn't log correctly on entry, you may want to see if it calculates properly when edited.

7
  • It wouldn't work on edit because the workflow would be paused.
    – Erin L
    Mar 3, 2016 at 16:32
  • Not sure I understand your comment, if the workflow is set to start on entry and edit it would not be paused once the item is saved.
    – DigiZen
    Mar 3, 2016 at 16:36
  • From your answer... "Pause until Variable:Reminder Date"... so if the Due Date changes before the reminder has been sent, the workflow will still be paused and not detect a change. It can't restart on that edit because it's already running.
    – Erin L
    Mar 3, 2016 at 18:32
  • Erin- You scared me, I ran to my test server to try this out. I might not have been clear enough distinguishing between editing the workflow and editing the item. If the workflow is entered as described above with the start workflow on edit enabled, then when the item is edited the workflow will restart and recalculate the variable. I hope I am describing what I just successfully tested accurately enough to clarify.
    – DigiZen
    Mar 3, 2016 at 21:19
  • What due date did you start with and what due date did you change it to when you edited it?
    – Erin L
    Mar 3, 2016 at 22:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.