USD – window.IsUSD

Within Unified Service Desk (USD) for Microsoft Dynamics CRM sometimes you might wish to create some functionality on a CRM form that only happens whilst in USD.

The can be achieved by using a window.IsUSD command in your JavaScript. This command will return true when in USD and false when not. Simples.

To demonstrate this I added a simple check to my on load event in my contact form. The simple code looked like this;

function onLoad() {

if(window.IsUSD == true) {

alert("This form is being loaded in USD!");

} else {

alert("This form is being loaded NOT in USD!");



When I load in USD I get this. And you can guess what happens when I’m not in USD.

Hopefully you can see how this simple command might be helpful. J


Update: Recently I have faced a challenge in using window.IsUSD withe the newer Unified Interface. If you hit problems, try “parent.window.IsUSD”. As that worked for me.

4 thoughts on “USD – window.IsUSD

  1. Pingback: USD – The Book | Microsoft Dynamics CRM and Unified Service Desk

  2. Pingback: JavaScript – My Collection - Microsoft Dynamics CRM Community

    • I have never had an issue with this! I think it might return undefined outside of USD. But inside I have not seen an issue. What version of USD are you using?

      From your comment you mean it works some of the time? I haven’t observed any reliability issues. Is there any pattern to when it fails?


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s