Export (0) Print
Expand All

How to: Add the CrmService Web Reference

banner art

[Applies to: Microsoft Dynamics CRM 4.0]

Find the latest SDK documentation: CRM 2015 SDK

You can add the CrmService Web Services Description Language (WSDL) to your Microsoft Visual Studio project by using the URL of your Microsoft Dynamics CRM server. Notice that the WSDL file changes as you customize the entities for your organization. When this happens you can save a new WSDL file and then update the Web reference in your project.

To add the Web reference using Visual Studio 2005

  1. Open your Visual C# or Visual Basic .NET project in Microsoft Visual Studio 2005.
  2. In the Solution Explorer pane, right-click References.
  3. Click Add Web Reference.
  4. In the URL field, paste the following string, replacing <server name> with the name of your Microsoft Dynamics CRM Server and organizationName with the name of your organization. The TCP port number in the Web service URL is optional and only required if Microsoft Dynamics CRM is installed to a nondefault Web site on the server.
    http://<servername[:port]>/mscrmservices/2007/crmservice.asmx?WSDL&uniquename=organizationName
    
  5. Click Go.
  6. Edit the Web reference name. This is the name that you will put in the Using statement in your source code. For this example enter CrmSdk.
  7. Click Add Reference.

The Microsoft Dynamics CRM Web service is now added to your project. In your source code you can refer to the classes available in this SDK.

To add the Web reference using Visual Studio 2008

  1. Open your Visual C# or Visual Basic .NET project in Microsoft Visual Studio 2008.
  2. In the Solution Explorer pane, right-click References.
  3. Click Add Service Reference.
  4. Click Advanced… button.
  5. Click Add Web Reference… button.
  6. In the URL field, paste the following string, replacing <server name> with the name of your Microsoft Dynamics CRM Server and organizationName with the name of your organization. The TCP port number in the Web service URL is optional and only required if Microsoft Dynamics CRM is installed to a nondefault Web site on the server.
    http://<servername[:port]>/mscrmservices/2007/crmservice.asmx?WSDL&uniquename=organizationName
    
  7. Click Go.
  8. Edit the Web reference name. This is the name that you will put in the Using statement in your source code. For this example enter CrmSdk.
  9. Click Add Reference.

The Microsoft Dynamics CRM Web service is now added to your project. In your source code you can refer to the classes available in this SDK.

See Also

Other Resources


© 2010 Microsoft Corporation. All rights reserved.


Show:
© 2015 Microsoft