This section helps you prepare for the implementation of services.
Check for service accessibility
Enter the service URL in the browser and test the availability of the service. The service URL has the following format:
http://[your-web-server]/SmartPlantReferenceDataPlus2011CMS/CmsServices.svc
The display in your browser should be similar to that shown below:
Once accessibility is checked, you must add the service reference in the consuming application source code. We are assuming that users are using Microsoft Visual Studio 2010. You can use the following procedure to add the service reference to the consuming application source code.
When you add the service reference, the following dialog box appears.
In the Address box, enter the new service address, and click Go. The Services box and Operations box display the service and all operations (methods), respectively.
Next, enter the namespace of the proxy class in the Namespace box, and click OK.
You can now see the added references in the project’s references (in the explorer view). A sample is shown below.
Note that besides generating a proxy class, Visual Studio also writes a section into your .config file when you add a Service Reference. This section is bounded by the “<system.serviceModel> </system.serviceModel>” tags. If you have generated the proxy in a class library project, you must copy this section to the executing assembly project's .config file.
You can also edit the timeout duration for the service channel. The following picture shows an example of where to set this timeout duration in the code.
The common input for the corresponding services is displayed below in the transfer object structure.
Parameter Name |
Remarks |
---|---|
ApplicationServiceUrl |
Smart Reference Data web service address. This address is the one used for accessing the Smart Reference Data client. |
DisciplineCode |
Smart Reference Data discipline code |
HostString |
Smart Reference Data host string |
Password |
Smart Reference Data password |
ProductGroupCode |
Smart Reference Data product group code |
ProjectId |
Smart Reference Data project identifier |
LanguageDesc |
Smart Reference Data language description |
UserName |
Smart Reference Data user name |