Frage

The netsuite documentation indicates to use NetSuiteService; but I cannot find that object to instantiate. I have NetSuitePortTypeClient instead. Was a step missed when I imported the Service Reference?

I followed the instructions on page 23 of this documentation: http://www.netsuite.com/portal/partners/integration/download/SuiteTalkWebServicesPlatformGuide_2013.1.pdf

War es hilfreich?

Lösung

The NetSuite/SuiteTalk documentation says to add a Web Reference, not a Service reference.

The Service Reference has the NetSuitePortTypeClient or NetSuiteChannelTypeClient classes. I don't know all the differences between the Service Reference and Web Reference technologies, but you have to provide more parameters for those to classes, that are provided automatically for you with the NetSuite class of a Web Reference. A Service Reference is generated with SVCUTIL.exe under the covers by VS for you.

The Web Reference has the NetSuite class you can instantiate. This is generated with WSDL.exe under the covers by VS for you. You can add a Web Reference in VS2010 down at the bottom left of the Add Service Reference form, click on Advanced, then click on Add Web Referenceat the bottom left again, and then enter the URL to where the WSDL is defined. Don't forget that NetSuite has multiple different versions, from 2010 up to 2014, so pick the most recent that works for you.

Use the Web Reference for NetSuite, it's easier.

Bo.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top