Dynamics CRM 2011 Web Address – Xrm.Page.context.getServerUrl | Record URL(Dynamic) workflow dynamic values

Xrm.Page.context.getServerUrl()

 

{Record URL(Dynamic)(Entity)}

The value returned by previously mentioned two ways can be changed by modify Dynamics CRM Web Address within Deployment Manager.



You can use the following to construct URL in FormLabrary

var serverUrl = document.location.protocol + '//' + document.location.host + '/' + Xrm.Page.context.getOrgUniqueName();

Xrm.Page.context.getServerUrl && Record URL(Dynamic) workflow dynamic values can return the base server URL which can be used either to construct web service URL (SOAP | REST) in FormLibrary or embed Record URL in a workflow.

According to SDK

The URL returned is the standard URL used to access the application. If you access the server locally using http://localhost or use an IP address rather than the actual name of the server, this will not be reflected in the value returned by this function. This means that if you are making web service calls or accessing web resources, Internet Explorer will apply security settings that apply to requests that cross domains. To avoid this, always connect to Microsoft Dynamics CRM using the standard URL.

Advertisements

Leave a Reply

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

WordPress.com Logo

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

Twitter picture

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

Facebook photo

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

Google+ photo

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

Connecting to %s