Saturday, 16 November 2013

Detect browser in crm 2013

How to detect browser in CRM ?

Hello CRM Lovers,
          Here is my findings, In this post i will share with you how to detect browser in CRM. It is not a big task, easy one.

I can understand the CRM developers requirements, because after release of CRM roll up 12 and CRM 2013, we can access CRM on cross browsers also. when we did customization with java script functionality, It may vary browser to browser, so there may be need of browser detection in CRM 2011 and in CRM 2013. So here is the simple java script code for CRM and it will work in CRM 2011(rollup 12) as well as in CRM 2013.

Add the fallowing code to your crm java script web resource.

         Mscrm.Utilities.isIE = function() {
             return Sys.Browser.agent === Sys.Browser.InternetExplorer

         function detectBrowser() {
            if (Mscrm.Utilities.isIE()) {
               alert("You are using IE");
             if (Mscrm.Utilities.isFirefox()) {
               alert("You are using Firefox");
            if (Mscrm.Utilities.isChrome()) {
               alert("You are using Chrome");

Enjoy the great technology Dynamics CRM. Good luck.....!!!!! 

No comments: