locked
Create Appointment with Javascript in CRM 4.0 RRS feed

  • Question

  • Hi,

    How can I create an appointment with requiredattendees ? (with javascript)
    I try to do following code, but it doesn't work.

    "<requiredattendees type='account'>"+AccountGUID+"</requiredattendees>"+

    How can I do this?

    ..........
      var authenticationHeader = GenerateAuthenticationHeader();
      var AppXml = "<?xml version='1.0' encoding='utf-8'?>" +
      "<soap:Envelope xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/'"+
      " xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'"+
      " xmlns:xsd='http://www.w3.org/2001/XMLSchema'>"+
      authenticationHeader+
      "<soap:Body>"+
      "<Create xmlns='http://schemas.microsoft.com/crm/2007/WebServices'>"+
      "<entity xsi:type='appointment'>"+
      "<subject>"+Title+"</subject>"+
      "<requiredattendees type='account'>"+AccountGUID+"</requiredattendees>"+
    .....


    MS CRM
    Wednesday, December 14, 2011 8:41 AM

Answers

  • Hi,

    Try :

     

    "<requiredattendees><activityparty><partyid type='account'>"+AccountGUID+"</partyid></activityparty></requiredattendees>"
    

    Regards,

     


    Philippe

    Blog : dynamicscrmcustomization

    Please remember to click "Vote as Helpful" and “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.


    Wednesday, December 14, 2011 12:15 PM

All replies

  • Hi,

    Try :

     

    "<requiredattendees><activityparty><partyid type='account'>"+AccountGUID+"</partyid></activityparty></requiredattendees>"
    

    Regards,

     


    Philippe

    Blog : dynamicscrmcustomization

    Please remember to click "Vote as Helpful" and “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.


    Wednesday, December 14, 2011 12:15 PM
  • Thank you Philippe.

    It works.


    MS CRM
    Friday, December 16, 2011 11:25 AM