locked
How to include crm Metadataservice, Microsoft.Crm.Sdk.Utility.CrmServiceUtility into my application. RRS feed

  • Question

  • Hi,

     Please anyone let u know.

     How to include crm Metadataservice, Microsoft.Crm.Sdk.Utility.CrmServiceUtility into my application.
     
    Monday, October 13, 2008 9:19 AM

Answers

  • Hi Natarajan,

    It is not a .dll but a class you need to add to your project. Essentially the old 3.0 CRMHelper class. If you've downloaded the 4.0 SDK, search for 'crmserviceutility.cs' and add to your project. Under
    4.0 SDK\server\reference\cs.

    Cheers,

    Karlo
    Monday, October 13, 2008 10:56 AM

All replies

  • HI Natarajan,

    For .dll's you need to right click on your project references, browse to the .dll (if not already in GAC) and select it. To access the individual classes directly a using (c#) statement is usualy best.

    For any web references (e.g. Metadataservice), you will need the full URI of the web service. For web applications, right click the web references folder and browse to the URI of the web service. For windows applications/plugins, you need to right click on the service refereces folder, browse to the URI and select the reference. Bottom left is an 'advanced' button, select that and click 'add web reference'. Once you have added a single web reference, the web references folder is created and any future web references may be added from this folder directly.

    Metadata for CRM 4.0 is located at :

    http://myserver:5555/mscrmservices/2007/metadataservice.asmx

    (assume your port is 5555).

    Cheers,

    Karlo







    Monday, October 13, 2008 9:34 AM
  • HI,

     Nice Helpful reply from u..

     I am not able to add Microsoft.Crm.Sdk.Utility into my application.

     How to add that one..
    Monday, October 13, 2008 10:02 AM
  • Hi Natarajan,

    It is not a .dll but a class you need to add to your project. Essentially the old 3.0 CRMHelper class. If you've downloaded the 4.0 SDK, search for 'crmserviceutility.cs' and add to your project. Under
    4.0 SDK\server\reference\cs.

    Cheers,

    Karlo
    Monday, October 13, 2008 10:56 AM
  • I think you can achieve in following two ways:

    1. Build your own code library project, add that class into the project and compile it into dll. Then add that dll into your poject.

    You can then call the method of the utility class like you call any other third party code.

    2. Create a new class file in your project and add the code of the CrmServiceUtility class into your project, then you can call that method directly.

    Hope that helps

    Friday, July 10, 2009 5:08 AM
    • Proposed as answer by KumarXRM Friday, April 22, 2011 8:08 PM
    Thursday, April 14, 2011 4:30 PM