SharePoint Designer Workflow – Send Email Reminder X days prior to a Date

by oscar 6/24/2008 2:12:15 PM

Business Problem


One of my clients wanted to send email reminders to users one week prior to the project assigned tasks Due Date.

Solution


As you may or may not know, MOSS does not have that built-in functionality, but it is easily accomplished via a workflow created using the SharePoint Designer 2007.

Architecture

Calculated Column
I feel that working with complex date calculations (view my other post for a more date formulas  SharePoint List Calculated Column - Calculate Business Days) are best done on the SharePoint List side.  Therefore, I decided to have a calculated column that would already have the DateTime for when I need to send my Email Alert.

In this scenario it was fairly straight forward and so my formula simply looks like this:
image

This is what the column looks like when viewing the list items.  If you look closely, you will see that the column Days Prior To Due Date shows 3 days, but my email reminder column says the date to send my email is 6/21/2008.  The reason is that the formula on that column excludes weekend days!  image 

Workflow

The first Step on the workflow – Set Reminder Time

  • I use the Add Time To Date Action, but don’t actually add time, I simply capture the value of the column TaskEmailReminderDate and store it on a variable called ReminderDate for use on my Step 2.
  • Store the Task Title on a variable called SubjectTaskTitle, used when sending my email
  • So that I can debug, I simply use the Log To History List Action to view the value of the ReminderDate variable



image

The Second Step on workflow – Send Task Reminder Email

There are no conditions, this step simply uses the Pause Until Date Action and uses the variable on Step 1 called ReminderDate to send out my email.
image


NOTE:
When I was testing my workflow, I was of course logged in as the “Administrator”, and so the workflow always failed to start automatically!  View this KB article for details.  My resolution was to simply create another account in AD and grant that account admin rights to my portal.  This prevented me from updating the Application Pool Identity for my Web Application.

Well I hope this helps you and let me know if it did!

Cheers,
Oscar

Currently rated 3.0 by 2 people

  • Currently 3/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

Calculated Fields | SharePoint Designer | MOSS 2007 | WSS 3.0

Related posts

Comments

7/11/2008 4:22:10 AM

Hi C,

I suppose you can, if you grab the value of your "business Days" calculated column and check for the number of days it returns. If the number is what you are looking for, then display some message for example.

I would try to add an additional calculated column that checks the value of the "business days" calculated column to do this.

Let me know if that helps,
Oscar



Oscar us

9/5/2008 2:18:25 AM

Hi Rajpal,

If the List you are attaching your SPD Worlfow to is a Calendar List, yes. You should be able to lookup the value of the calendar event start date on your workflow and base your calculations out of that date.

Oscar us

Add comment


 

  Country flag





Live preview

11/21/2008 3:42:37 PM

Powered by BlogEngine.NET 1.2.0.0
Theme by Mads Kristensen

About Me

Oscar Medina I am a SharePoint Solutions Architect based out of San Francisco, California.
You can read more about me here

E-mail me Send mail
View Oscar Medina's profile on LinkedIn

Calendar

<<  November 2008  >>
MoTuWeThFrSaSu
272829303112
3456789
10111213141516
17181920212223
24252627282930
1234567

View posts in large calendar

Recent comments

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2008

Sign in