2

While debugging web resources in Dynamics crm 9.0 I found that Form context always has a property context that is a reference to a global context.

The provided global context is fully functional and very useful especially in home page ribbons.

Why such important property formContext.context is not listed/ documented in Microsoft topics and articles? Is it supported?

enter image description here

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129

1 Answers1

0

Undocumented is unsupported.

The previous equivalent Xrm.Page.context is deprecated now.

getGlobalContext method provides access to the global context without going through the form context. It contains an equivalent of all the methods available for the Xrm.Page.context object (now deprecated) to retrieve information specific to the client, organization or user.

To get the global context in supported way, use Xrm.Utility.getGlobalContext(), this will return the same expected formContext.context.

Who knows when & where formContext.context will break (like UCI) or get changed in future, but MS will give you through Xrm.Utility