locked
Send e-mail when ownership is assigned? RRS feed

  • Question

  • Hello Everybody,

    I have a Task list and set the Send e-mail when ownership is assigned? to yes

    The subject of the email received consists of the following  List Name+List Title+ "has been reassigned"
    I would like to change the subject of the email from List Name+List Title+ "has been reassigned" to List Name+List Title+ "has been changed"

    Any suggestions or solutions for this problem.

    Thanks in advance

     

     

    Tuesday, August 4, 2009 6:01 PM

Answers

  • Perhaps you can set "Send e-mail whn ownership is assigned" to false, and then manually create a workflow that sends an e-mail according to your specifications, using SharePoint Designer.
    Visit my blog at blog.beckybertram.com or follow me on Twitter: @beckybertram
    Wednesday, August 5, 2009 2:47 AM
  • Hi,

      

       If you did not want to use alert for the list, eventhandler with  customized SendMail logic can be a solution.

     

       You can check the changes of field  “AssignedTo” of ItemUpdating event to send the e-mail, in which you can define the mail title dynamically.

     

       -----------------------------------------------------------------------------------------------------------------

       public override void ItemUpdating(SPItemEventProperties properties)

       {

           //Use ListItem to get original Value

           string originalValue = properties.ListItem["AssignedTo"].ToString();

     

           //Use AfterProperties to get changed Value

       string reassignedValue = properties.AfterProperties["AssignedTo"].ToString();

       if(your condition)

       {

            //Here send mail

       }

     

    }

       -----------------------------------------------------------------------------------------------------------------

     

    Hope this can help.

     

    Best Regards,

    -Aaron.

    Tuesday, August 11, 2009 9:27 AM

All replies

  • http://blogs.msdn.com/sharepointdeveloperdocs/archive/2007/12/07/customizing-alert-notifications-and-alert-templates-in-windows-sharepoint-services-3-0.aspx

    You need to look at:

    SPAlertTemplateType.Tasks

    Notification of changes in tasks


    SSA - http://sharepointblogs.com/ssa
    Tuesday, August 4, 2009 6:08 PM
  • I don't want to set up an alert for the list. I am only setting Send e-mail when ownership is assigned? to yes and it will automatically generating email. But, i want to make change to the default subject of the email only.
    Tuesday, August 4, 2009 7:02 PM
  • Perhaps you can set "Send e-mail whn ownership is assigned" to false, and then manually create a workflow that sends an e-mail according to your specifications, using SharePoint Designer.
    Visit my blog at blog.beckybertram.com or follow me on Twitter: @beckybertram
    Wednesday, August 5, 2009 2:47 AM
  • Hi,

      

       If you did not want to use alert for the list, eventhandler with  customized SendMail logic can be a solution.

     

       You can check the changes of field  “AssignedTo” of ItemUpdating event to send the e-mail, in which you can define the mail title dynamically.

     

       -----------------------------------------------------------------------------------------------------------------

       public override void ItemUpdating(SPItemEventProperties properties)

       {

           //Use ListItem to get original Value

           string originalValue = properties.ListItem["AssignedTo"].ToString();

     

           //Use AfterProperties to get changed Value

       string reassignedValue = properties.AfterProperties["AssignedTo"].ToString();

       if(your condition)

       {

            //Here send mail

       }

     

    }

       -----------------------------------------------------------------------------------------------------------------

     

    Hope this can help.

     

    Best Regards,

    -Aaron.

    Tuesday, August 11, 2009 9:27 AM