Quantcast
Channel: Microsoft Dynamics 365 Community
Viewing all articles
Browse latest Browse all 64797

Convert XrmServiceContext to the IOrganizationService

$
0
0
A Quick post, If you use the Early Bound and you use the XrmContext strong-typed type method, but you think you miss the way you initialize the IOrganizationService in CRM, you can convert it by typing the following code..

XrmContext xrmContext = new XrmContext();
IOrganizationService service = xrmContext;

image

Hereafter, you can access your service object easily.

Hope this helps.

Thanks.

Viewing all articles
Browse latest Browse all 64797

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>