locked
HTML Webresouce Search and Create Record in CRM 2011 RRS feed

  • Question

  • Hi,

    There is a requirement on click of 'New' button the HTML web resource will be populated instead of new CRM form .There are 3 Fields like 1. First Name 2. Last Name 3. Phone Number .

    3 Buttons: like 1.Search 2. Create New Record 3. Cancel 

    Initially 'Create New Record' button was disabled .First User will search the records ( Like Search ) If the record does not exist it will prompt for new  record Creation then 'Create New Record' Button will be enabled .

    On Click of Create new button the details entered on HTML web resource will be pushed to CRM form respective field .

    Issue : As I am using XrmServiceToolkit.js while searching :

    var fetchXML = getPersonData();

           

    var fetchedResults = XrmServiceToolkit.Soap.Fetch(fetchXML);

           

    if (fetchedResults != null && fetchedResults.length > 0) {

    After this condition while debugging on file 'XrmServiceToolkit.js' at

    req.send(soapXml);

    it throws error like :-

    'Javascript runtime error : NetworkError'

     Or Is there any alternate way to achieve this please suggest for the same .

    Thanks

    Tuesday, May 6, 2014 6:54 AM

All replies

  • Hi Sudgol,

    I suggest using the Dynamics CRM SDK sample code to execute REST calls to fetch, create records in Dynamics CRM.

    In the CRM 2013 SDK, you can get the sample codes in this path: "SDK\SampleCode\JS\RESTEndpoint".


    Admin QuikView Solution for CRM 2013

    Tuesday, May 6, 2014 5:28 PM