locked
Notes in Email RRS feed

  • Question

  • Dear all,

    I am working in ms crm 4.0. i need to send the notes of one custom entity to email. is it possible?
    please help me..

    Regards

    Arun
    Sunday, March 7, 2010 10:25 AM

Answers

  • Hi Arun

    You can use Retrieve method to obtain the details of your record (MOM).
    Refer http://msdn.microsoft.com/en-us/library/aa613637.aspx

    // Set up the CRM Service.
    CrmService service = new CrmService();
    service.Credentials = System.Net.CredentialCache.DefaultCredentials;

    // Create the column set object that indicates the fields to be retrieved.
    ColumnSet cols = new ColumnSet();

    // Set the properties of the column set.
    cols.Attributes = new string [] {"fullname"};

    // MOMGuid is the GUID of the record being retrieved.
    Guid MOMGuid = new Guid("4D507FFE-ED25-447B-80DE-00AE3EB18B84");

    // Retrieve the MOM.
    // The EntityName indicates the EntityType of the object being retrieved.
    MOM MOMrecord= (MOM)service.Retrieve(EntityName.MOM.ToString(), MOMGuid, cols);


    Regards
    Vinoth
    • Marked as answer by Jim Glass Jr Thursday, March 11, 2010 4:18 PM
    Tuesday, March 9, 2010 7:10 AM
  • You can Get the GUID of each MOM record by passing it to the IFRAME page using the builtin option provided In CRM.

    Regards
    Vinoth
    • Marked as answer by Jim Glass Jr Thursday, March 11, 2010 4:18 PM
    Tuesday, March 9, 2010 7:13 AM

All replies

  • Hi, Arun.

    You can set up a workflow. Firing entity must be annotation. Check Create checkbox, select Organization level. Add step which will send email with Description field of annotation. Publish email.
    Truth is opened the prepared mind

    My blog (english)
    Мой блог (русскоязычный)free countersLocations of visitors to this page
    Sunday, March 7, 2010 10:58 AM
    Moderator
  • Hi Andriy,

    i tried as you mentione dabove and its working fine.

    i need this email to sent to selected user. i will clear you with an example..

    i have one custom entity named "Minutes of Meeting", in the Genaral tab i created a IFRAME and show the fields in iframe.it includes one dropdown with all usernames a button called "Add attendees". when i click that button i will get the attendies list one by one in a gridview for each click after selecting the user from the dropdown. i need to sent the email for those added attendees. how should i get the gridview details into CRM form, and it would be num of users.  so how should i achieve this.

    can you please give me any suggestions to achieve this..


    Regards

    Arun
    Monday, March 8, 2010 6:01 AM
  • Hi

    Create a button in your IFRAME page named "Send Email".

    Send email when the button is click using CRMWebservice email functionality.

    refer
    http://msdn.microsoft.com/en-us/library/bb959513.aspx
    http://nishantrana.wordpress.com/2008/07/11/creating-and-sending-email-in-crm/


    Regards
    Vinoth
    Monday, March 8, 2010 6:11 AM
  • Arun what type of grid you displayed in Iframe, Custom ASPX page or CRM Grid?
    And where you saved attendies list, in CRM?

    http://www.allaboutdynamics.com
    Monday, March 8, 2010 6:13 AM
  • Hi shahid,

    its a custom aspx page. the attendees are fetching from the systemuser entity..


    Regards

    Arun
    Monday, March 8, 2010 1:10 PM
  • Hi Arun

    Since you are using custom page its better to trigger the email functionality from the custom page itself.

    Create a button in your IFRAME page named "Send Email".

    Send email when the button is click using CRMWebservice email functionality.

    refer
    http://msdn.microsoft.com/en-us/library/bb959513.aspx
    http://nishantrana.wordpress.com/2008/07/11/creating-and-sending-email-in-crm/

    Regards
    Vinoth
    Tuesday, March 9, 2010 5:05 AM
  • Hi vinod,

    Thank you for the reply..i need to get the notes of "MOM" (custom entity) in the email's description. how will i take the notes that is mentioned in my custom entity.


    Regards

    Arun
    Tuesday, March 9, 2010 7:03 AM
  • If you place "Send E-mail" button then it only works in update case. (Record must be saved onces)
    1. Pass Guid of record to record to Iframe. (its property of Iframe)
    2. Allow cross browser scripting (property of Iframe)
    3. Get MOM record notes (annotation type record) using its MOM Guid in Custoem page.
    4. Add them to email discription and send mail as refer by Vinoth


    http://www.allaboutdynamics.com
    Tuesday, March 9, 2010 7:09 AM
  • Hi Arun

    You can use Retrieve method to obtain the details of your record (MOM).
    Refer http://msdn.microsoft.com/en-us/library/aa613637.aspx

    // Set up the CRM Service.
    CrmService service = new CrmService();
    service.Credentials = System.Net.CredentialCache.DefaultCredentials;

    // Create the column set object that indicates the fields to be retrieved.
    ColumnSet cols = new ColumnSet();

    // Set the properties of the column set.
    cols.Attributes = new string [] {"fullname"};

    // MOMGuid is the GUID of the record being retrieved.
    Guid MOMGuid = new Guid("4D507FFE-ED25-447B-80DE-00AE3EB18B84");

    // Retrieve the MOM.
    // The EntityName indicates the EntityType of the object being retrieved.
    MOM MOMrecord= (MOM)service.Retrieve(EntityName.MOM.ToString(), MOMGuid, cols);


    Regards
    Vinoth
    • Marked as answer by Jim Glass Jr Thursday, March 11, 2010 4:18 PM
    Tuesday, March 9, 2010 7:10 AM
  • You can Get the GUID of each MOM record by passing it to the IFRAME page using the builtin option provided In CRM.

    Regards
    Vinoth
    • Marked as answer by Jim Glass Jr Thursday, March 11, 2010 4:18 PM
    Tuesday, March 9, 2010 7:13 AM