{Dynamics 365 + Microsoft Apps} In-depth walkthrough on how to build and configure your own app using the App Designer

I have exploring the features of Dynamics 365 for sometime now and was just exploring this. Initially I was not some what reluctant to start getting hands on with this. But with time, as I started exploring, I started liking it more & more & more. And the reason? Well, it’s just configuration. You do not need any technical knowledge to do this and this puts you into a level playing field even if you are not from technical background. And you will be amazed to see how quickly you can configure your entire new app in just a matter of minutes.

So let’s get started. I have gone through some articles in this topic but honestly I did not find one which covers end-end walkthrough of how to enable, configure and publish an app. So I decided to pen this down so that it might help somebody ramping up on this wonderful feature.

The first question that now comes to mind? How to enable the APP Designer for your organization?

The APP Designer is a preview feature and you would need to enable it. Go to Settings –> Administration –> System Settings

Then navigate to Preview tab in the end of the pop-up. And enable “App Modules & App Designer Preview


Once done, now how to land on your APP Designer Page?

If you go to the ‘View All My Apps’ from the Admin section you would end up viewing all your apps but you won’t be able to edit your app.

Then? Don’t be disappointed. Let me give you a shortcut.

For e.g – My CRM URL is – https://xrmtr30.crm.dynamics.com. So to visit the APP designer for your page very quickly, just append applandingpage.aspx.  So the final URL would be – https://xrmtr30.crm.dynamics.com/applandingpage.aspx


Let us create a new APP. To do that click on the CREATE APP button.



Enter the details as required for the APP



I have used ‘default icon’ here. But you can use any webresource that you have uploaded for your application. Once you are done, you be thrown to the configuration page of the APP.

Let us design our demo APP like this

  • The app’s sitemap will show just the accounts.
  • The account will have only the account form and couple of views – ‘My Active Accounts’ and ‘Active Accounts’

Click on the Sitemap designer.


I added the ‘Workplace’ area.



In the Workplace area, I am going to add the ‘Accounts’ entity. Select Type = Entity and in the Entity select “Account”.


Great. Isn’t it so easy to go ahead and design a stiemap for your app with a wonderful GUI based editor. Believe me, the example I have shown here is very simple. However you can design a complex sitemap as well in matter of minutes. No exporting the solution, editing the sitemap and re-importing.

Click ‘Save & Close” in the Sitemap designer to move out of the designer area.

Now I will add the forms and views of the account entity.

Select “Forms” and then add the desired form.


Select the forms you want to add.


Click on Save & Close at the top. Next click on views.


Select the views you want.


You can select OOB views or you can create a new view as well for the APP.

Now Save & Close. And then click on publish on the top menu.


The app will now be visible in your APPS area.


Now I have created the APP.

But who should be able to view this APP?

Click on the ellipsis at the bottom of the the APP and then click on ‘Manage Roles’.


Select the roles for which the app should display.


I have chosen the System Administration & System Customizer role who should be able to view my custom app.

So all set and done! Let me browse my custom app.

And as you can see, there is just the account entity in the whole sitemap.


Also if you remember, I have selected three views only of the account



So you can see how easily we have created an APP for ourselves in a matter of minutes.

You can add dashboards, business process flows, charts & what not and that too through a wonderful UI.


Hope you have liked this post!


Debajit Dutta

(Visit www.xrmforyou.com products page to know more about our offerings)

{Dynamics 365 + Editable Grids} Rearrange columns on the fly and maintain view groupings and switch display mode in Dynamics 365 editable grids.

Editable grids are here and how and it’s WOW. Probably the most awaited feature of the Dynamics CRM since its inception. The entire community is going gaga over it and why not?

No this is not a blog post which tells you how to enable and configure editable grids. There has been lot of great posts already floating in the community and I will not add on top of that. Rather I would like to focus on two new cool features that has accompanied editable grid but are somehow hidden from its limelight. In case you are not aware of the editable grid feature in Dynamics 365, you can visit the below link to get acquainted with it.


So let us talk about these small and yet handy new features.

Column Re-arranging on the fly in Views

Now this is cool. When I first saw this, I am like finally! Now I can view the columns in order of my preference rather than some default ordering set up by my system customizer while not creating a view for myself.

For e.g -  I have enabled editable grid for my account entity and currently in the “Active Accounts” view, the column “Address 1 City” is after the “Main Phone”.

Well I do not like that. I want it to be displayed right after my account name column. Then go ahead. Simply drag the column and drop it before the “Main Phone” column.


And voila it is done.


Now that was easy! But it will go away if I move away from Accounts, view something else and come back? Well the good news is, in the same session it maintains your preferences. So if you move to Opportunities grid and come back to “My Active Accounts” view, you would still see your address1 city column displayed before the Main Phone column.

Same way, your grouping on the views is maintained in the same session.

In the below screenshot, I have grouped ‘My active Accounts’ with group by = “City”. Now when I moved to contacts and came back, the grouping is maintained.


Wondering if you need to refresh your CRM page for some reason, will your choice of grouping be still maintained? The answer is big “YES”.

So editable grids are great. But what I want to fall back temporarily to the default non-editable view without changing it through customizations. Well all you need to do is choose an option from the ribbon menu.


As shown in the above screenshot, select Read-Only Grid from the Show As menu and you are done.


Hope this helps! Stay tuned for more update on the amazing Dynamics 365 features.


Debajit Dutta (Dynamics MVP)

(Visit www.xrmforyou.com products section to find our offerings)

{Dynamics 365} Preview Feature – Organization Insights Dashboard


A new reporting component to provide organization insights has been added in Dynamics 365. These charts can be added to a dashboard and provide the mentioned below information


a) Active Users – Number of users that are logged at different times of the day.

b) Active Users Performing Specific Operations – Number of Different operations(Create, Update, Delete and Read) performed by active users at different times of the day.

c) Most Active User (Changes) – Number of changes (Create, Delete, Update) performed by different users past 2hours, 48`hours or past 30 days.


d) Total Page Requests – Page requests in classification of Dashboards, Reports and forms at specific times.

e) Total Operations – Total number of operations Create, Delete Update and Read happening at specific times.

f) Most Active Users – Read operations performed by the most active users.

For using organization insights, we need to be firstly configure them…

View original post 16 more words

{Dynamics 365 New Features} Explore the new OOB Actions available with Dynamics 365

Some more research and yet another blog post to highlight another excellent feature of Dynamics 365. I have been extoling Dynamics 365 and I am tired as the more I explore, the more I get amazed by it. So without wasting much time, let me straight get to the point here.

With Dynamics 365, a whole new set of actions has been provided to you OOB. As per MSDN documentation, the following are the new set of actions available with this release.

  • Add (Case) to Queue
  • Add user to Record Team
  • Apply Routing Rule (to Case)
  • Calculate Actual Value (of Opportunity)
  • Close Opportunity
  • Get Quote Products from Opportunity
  • Get Sales Order Products from Opportunity
  • Lock Invoice Pricing
  • Lock Sales Order Pricing
  • Qualify Lead
  • Remove User from Record Team
  • Resolve Incident
  • Resolve Quote
  • Revise Quote
  • Unlock Invoice Pricing
  • Unlock Sales Order Pricing

I know your hands might be itching now already to try all these out. But reading never hurts Winking smile

I will not go through all the actions mentioned in the list. Rather let us explore some of the common.


Add user to Record Team

This is the first action that came to my notice. And let’s explore this.

I create a workflow with Entity = “Opportunity” and made it on-demand.



The next step is to call the OOB Action. For this, I just select ‘Perform Action’ step and select the ‘Add user to Record Team’ action from the list of available actions.



Click on Set Properties and populate the input parameters of this action



In the above step, I add the created by user to the Opportunity Team of the opportunity on which the workflow is currently running. I activate the workflow and then move to an opportunity record.

I have inserted the Access Team grid in the Opportunity form as ‘Opportunity team’ and currently as you can see in the screenshot below, there are no records in this grid.



Now I select the Workflow and run it. And voila, the opportunity created by is added to the grid.




Qualify Lead

Nothing special here. As usual, you select the ‘Qualify Lead’ Action then set the appropriate input parameters.

Depending on this choices you select in the Input parameter, the lead is Qualified. You can go for static values for dynamic values for the input parameters just like with any other workflows.



I leave up to you to get dirty with the remaining Actions.

Stay tuned for more exciting features on Dynamics 365.


Debajit Dutta

(Visit www.xrmforyou.com products page for offerings)

{Dynamics CRM/365 + WebAPI} Get the created object after creating a record using Web API in Dynamics 365

Another blog post and with it another great feature of Web API enhancements in Dynamics 365 that I will be sharing it. A small enhancement but a really handy one I would say.

So let’s understand what this feature I am talking about. If you just saw the header and jumped into this post without really understanding much from the title of this topic, don’t be disappointed. It’s my bad and I am terrible to in finding click bait headers for my topics. Hope I will do a decent job explaining the feature. So buckle up.

Prior to Dynamics 365, when you create a record in Dynamics CRM, be it through Web API or through Organization Service, you would get the guid of the newly created record back. And to get the whole object back you would again need to query the with the returned guid.

The problem become more prominent if you are using the deep insert feature using Web API. For example when I create a account, I can create an associated contact in the same operation. However after the create operation, all you get back is the guid of account record.

Well if you have been bothered by this, no need to worry anymore. The awesome Dynamics 365 is here to bail you out.

With Dynamics 365, you can pass an optional parameter in the header of the request to return the created record if you wish to. In the below example, I am creating an account record and an associated contact record as well and then returning the whole account record

function createAccount() {

    var serverURL = Xrm.Page.context.getClientUrl();
    var account = {};
    account["name"] = "Web API representation example";
    account["address1_city"] = "Bangalore";

    account["primarycontactid"] = {
        "firstname": "Debajit",
        "lastname": "Dutta"

    account["numberofemployees"] = 1000;

    var req = new XMLHttpRequest();
    req.open("POST", serverURL + "/api/data/v8.2/accounts", false);
    req.setRequestHeader("Accept", "application/json");
    req.setRequestHeader("Content-Type", "application/json; charset=utf-8");
    req.setRequestHeader("OData-MaxVersion", "4.0");
    req.setRequestHeader("OData-Version", "4.0");
    req.setRequestHeader("Prefer", "return=representation");
    var response = req.responseText;

The key in the above code is the line highlighted. Infact if you do not pass the above, the request internally sends a default header of return=minimal and that’s why all we get back is the guid of the created record.

Below is the JSON result I get back:



  "@odata.context":"https://xrmtr30.crm.dynamics.com/api/data/v8.2/$metadata#accounts/$entity","@odata.etag":"W/\"642226\"","openrevenue_date":"2016-11-02T15:02:27Z","territorycode":1,"address2_freighttermscode":1,"address2_shippingmethodcode":1,"accountid":"785a73fc-73a1-e611-80e6-c4346bac4500","statuscode":1,"creditonhold":false,"donotbulkemail":false,"donotsendmm":false,"createdon":"2016-11-03T03:17:02Z","statecode":0,"businesstypecode":1,"donotpostalmail":false,"_ownerid_value":"e4306322-8b0f-4cb4-93e9-1d2da3169fdd","donotbulkpostalmail":false,"name":"Web API representation example","address1_city":"Bangalore","donotemail":false,"donotphone":false,"address1_composite":"Bangalore","address2_addresstypecode":1,"versionnumber":642226,"opendeals_date":"2016-11-02T15:02:27Z","_modifiedby_value":"e4306322-8b0f-4cb4-93e9-1d2da3169fdd","shippingmethodcode":1,"followemail":true,"preferredcontactmethodcode":1,"numberofemployees":1000,"_owningbusinessunit_value":"e8d2b7eb-199e-e611-80ea-c4346bacda3c","_primarycontactid_value":"795a73fc-73a1-e611-80e6-c4346bac4500","_createdby_value":"e4306322-8b0f-4cb4-93e9-1d2da3169fdd","donotfax":false,"merged":false,"customersizecode":1,"marketingonly":false,"accountratingcode":1,"address2_addressid":"e836a8b7-c4f7-44b4-b46e-344c3d312622","_owninguser_value":"e4306322-8b0f-4cb4-93e9-1d2da3169fdd","modifiedon":"2016-11-03T03:17:02Z","participatesinworkflow":false,"accountclassificationcode":1,"address1_addressid":"13b1f69c-6b06-4990-be7e-2ab502b71b19","openrevenue":null,"lastusedincampaign":null,"address1_name":null,"address1_telephone2":null,"overriddencreatedon":null,"entityimageid":null,"ownershipcode":null,"creditlimit":null,"address1_county":null,"entityimage_timestamp":null,"telephone3":null,"address1_freighttermscode":null,"address2_line1":null,"onholdtime":null,"int_twitter":null,"_createdbyexternalparty_value":null,"telephone2":null,"primarysatoriid":null,"address2_telephone1":null,"address1_fax":null,"_createdonbehalfby_value":null,"address2_city":null,"address2_latitude":null,"address2_composite":null,"creditlimit_base":null,"aging90_base":null,"address2_postalcode":null,"address2_name":null,"preferredappointmentdaycode":null,"_owningteam_value":null,"address2_line3":null,"revenue_base":null,"aging30":null,"ftpsiteurl":null,"_originatingleadid_value":null,"emailaddress3":null,"_modifiedbyexternalparty_value":null,"paymenttermscode":null,"websiteurl":null,"revenue":null,"address1_shippingmethodcode":null,"description":null,"tickersymbol":null,"lastonholdtime":null,"marketcap":null,"_parentaccountid_value":null,"_preferredsystemuserid_value":null,"address2_longitude":null,"_defaultpricelevelid_value":null,"openrevenue_state":null,"address1_primarycontactname":null,"accountcategorycode":null,"marketcap_base":null,"address2_telephone3":null,"address2_postofficebox":null,"_preferredserviceid_value":null,"importsequencenumber":null,"address1_upszone":null,"stageid":null,"utcconversiontimezonecode":null,"aging60":null,"customertypecode":null,"telephone1":null,"opendeals_state":null,"address1_postofficebox":null,"yominame":null,"address2_country":null,"address1_line2":null,"address1_postalcode":null,"traversedpath":null,"_transactioncurrencyid_value":null,"fax":null,"address2_upszone":null,"aging90":null,"address1_longitude":null,"emailaddress2":null,"address1_telephone1":null,"exchangerate":null,"address1_stateorprovince":null,"address2_line2":null,"entityimage":null,"primarytwitterid":null,"timespentbymeonemailandmeetings":null,"accountnumber":null,"address1_line1":null,"_territoryid_value":null,"_slaid_value":null,"address2_county":null,"_preferredequipmentid_value":null,"sic":null,"entityimage_url":null,"processid":null,"address2_telephone2":null,"address1_addresstypecode":null,"address1_utcoffset":null,"address2_fax":null,"aging60_base":null,"address1_country":null,"_modifiedonbehalfby_value":null,"stockexchange":null,"address1_line3":null,"int_facebook":null,"aging30_base":null,"openrevenue_base":null,"sharesoutstanding":null,"_slainvokedid_value":null,"address2_primarycontactname":null,"address1_latitude":null,"_masterid_value":null,"address2_utcoffset":null,"emailaddress1":null,"timezoneruleversionnumber":null,"opendeals":null,"address2_stateorprovince":null,"preferredappointmenttimecode":null,"industrycode":null,"address1_telephone3":null


As you can see, not only I get the account record back but also the GUID of the primary contact associated with the entity record that I created using deep insert.

Please note that the status of the response would be 201 (Created).

Stay tuned for another wonderful update from the world of Dynamics CRM


Debajit Dutta

(Visit http://www.xrmforyou.com/products.html and checkout our tools library)

{Dynamics CRM/ 365 + Web API} New Metadata Query features in Web API in Dynamics 365

Dynamics 365 is in and just like me, CRM enthusiasts all over the world are simply WOW’ed by its wonderful offerings. After all, this has been a giant leap by Microsoft and indeed a great opportunity for all consultants to me to plunge into unknown territories and conquer it.

In this blog post, I will walk you through the new Metadata Query features that has been introduced with Dynamics 365 Web API. Off late I have been developing some tools using were using the WEB API endpoint and these new additions to the WEB API will really help developers to query the metadata in a very simple way. So without wasting more time, let me straight way give you a flavor of this.

With Dynamics 365, the Web API endpoint has been upgraded to v8.2. So it would be typically in this format – /api/data/v8.2/">https://<organizationUrl>/api/data/v8.2/

For my trial organization, below is the screenshot.


Now comes the interesting part which is querying the metadata.

Below are some of the scenarios I explored and it works like a charm. I will show all the examples here related to the “contact” entity for my organization. The best thing that you find in the below examples is, using the Web API you can query the same way you do in organization service for your CRM Metadata.


Query Entity Metadata


Isn’t it great! You can query the entity metadata using the EntityLogicalName just like you do in Organization Service.

And below is the JSON result I get which you just need to parse to get your data back.



Query Entity Metadata along with all attributes


And below is the sample JSON response for the field ‘First Name’



Querying single Field Metadata

So how about you want to query just a single field metadata. Well dynamics 365 is not here to disappoint you Smile

In the below query, I have just queried for the firstname metadata for the contact entity.


And below is the JSON response.



Querying global Optionsets

Enough of querying fields specific to entity. How about global optionset? And yet again Dynamics 365 has your back.


In the above example, I am querying for the metadata of a global optionset called ‘decisionmaker’. And below is the sample JSON response.



Querying Relationships

The below query will query for the N:N relationship between contact and leads


And below is the JSON response for the same



I am still exploring the wonderful features of Dynamics 365 and stay tuned for another interesting update.


Debajit Dutta

(Visit http://www.xrmforyou.com/products.html and checkout our tools library)