Quantcast
Channel: Sam's Activities
Viewing all articles
Browse latest Browse all 3363

Create Record using Custom Button in CRM 365 and java Script

$
0
0

Hello Guys,

I am using below code to create new record in CRM using Javascript. Code is working fine if i call the method on Load of the form. But if i call the method on Custom Button. it stop working. please suggest what i am missing.


function GenerateRecord() {
debugger;
 var dummy = {};
 dummy.dam_name = "Test";
 //Create the dummy
 SDK.REST.createRecord(
     dummy,
     "dam_dummy",
     function (dummy) {
            },
     errorHandler
   );
// this.setAttribute("disabled", "disabled");
}

function errorHandler(error) {
// writeMessage(error.message);
}


Viewing all articles
Browse latest Browse all 3363

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>