Skip to main content

Posts

Showing posts from June, 2019

Dynamics 365 Open Quick Create Form and Save/Refresh calling record

If you are working in a scenario where you have to open Quick Create Form through JavaScript and save/refresh the calling record after the quick create form has been saved, you have few choices. In this article I will show you how you can leverage the async and await operators in JavaScript to solve this scenario. First thing let’s try to define async and await Async : - pretty much a function that returns a promise Await : - makes JavaScript wait until the promise has been settled. First thing let’s define the function that is going to Open Quick Create Form function QuickCreate() {     var entityFormOptions = {};     entityFormOptions[ "entityName" ] = "contact" ;     entityFormOptions[ "useQuickCreateForm" ] = true ;     // Set default values for the Contact form     var formParameters = {};     formParameters[ "firstname" ] = "Sample" ;     formParameters[ "lastname" ] = "Contact