No I am not going to put any MSDN link or try to explain how can you debug your scripts in tablet forms efficiently. After all we are in the world of interesting world of Dynamics 365 and writing something like that will be pretty banal.
However I am going to let you know one trick through which you can leverage the power of Developer tools of Chrome to debug your CRM scripts in tablets. And you might have been thinking that is something I have pulled out of my sleeve. Well, it’s not me but the brilliant ‘Dynamics CRM Tip of the Day’ (http://crmtipoftheday.com/) guys where from I learnt this trick.
I was in one of the recent customer engagements and the customer was keen to bring in support for tablets and mobiles. They had some heavy customizations and they were getting left and right script errors when the forms were loading in tablets. Putting Xrm.Utility.alertDialog will only get you that far. And it was surprising that in-spite of they being pretty good on the platform, they were not aware of this trick suggested by ‘Dynamics CRM Tip of the Day’ guys. Below is a link to the same.
I wonder why this is not suggested in many cases but this might really save you some serious time.
It’s a pretty old tip and hence I think people are not aware of it. Hence re-sharing. Believe me, after knowing this, if someone asks you to debug mobile scripts, you will find it easy like a piece of cake. And believe me, every tip I their blog is like gold dust.
I have been using it for pretty long time and yes it works for all versions. I have tried in Dynamics 365 and Dynamics 365 on-premises and it works like a charm. However do note that this works only in Chrome as far I have tested.
Sample Dynamics on-Premise with IFD url to access the mobile form in desktop browser.
Sample Dynamics 365 online url to access the mobile form in Desktop browser (North America Orgs)
You need to first launch chrome, put your Dynamics URL and then login. Once logged in successfully, take the mobile Url and paste in your browser. You should be good.
Debugging scripts is now just like the web client. All you need to do is put a debugger statement in script function you want and then just launch Chrome developer tools using F12. That’s all.
Below is the sample of screenshot of my Dynamics 365 on mobile client.
Hope this helps.
Try our tools
Sharepoint Metadata Manager and Attachment Extractor (http://www.xrmforyou.com/sharepoint-integrator-1.html)
Role Based Views in Dynamics CRM (http://www.xrmforyou.com/role-based-views.html)
Multiselect Picklist Control (http://www.xrmforyou.com/multi-select-picklist.html)
Record Cloner (http://www.xrmforyou.com/record-cloner.html)