Using SvcUtil.exe

You can use SvcUtil.exe to generate a proxy and the configuration settings that define how to connect to the native endpoint for the Dynamics GP service. This may be necessary if Visual Studio cannot create the appropriate entries in the app.config for the service reference you add to your project. Complete the following procedure to use SvcUtil.exe to generate a proxy and configuration settings.

  1. Open a Visual Studio Command Prompt window.

    Click the Start menu, click Visual Studio, click Visual Studio Tools, and then click Visual Studio Command Prompt.

  2. Set the current folder.

    In the command prompt, se t the current folder to the location where you want the generated proxy and configuration files to be created.

  3. Run SvcUtil.exe to generate the output files.

    To use svcutil.exe you need to provide the URL of the native endpoint for the Dynamics GP service and the namespace of the service reference you added to your Visual Studio project. Typically, this is "DynamicsGPService".

    Enter the following on a single line and then press Enter.

    svcutil.exe http://<machine>:<port>/Dynamics/GPService /n:*,DynamicsGPService

  4. Use the generated files.

    If you choose to, you can use the generated proxy in your project. You can also use the generated configuration settings in the app.config for a Visual Studio project. In a text editor, open the output.config file created by SvcUtil.exe. Copy the <system.serviceModel> node from the ouput.config file and add it to the app.config file of your Visual Studio project.