Object reference not set to an instance of an object error when consuming a web service exposed by the PeopleSoft Integration Broker
This error prevents adding the bindings from the web service to a Visual studio project even after using the svcutil tool to generate the wsdl and xsd files.
To fix this error, open the wsdl file in a text editor like notepad++
Open the wsdl types collection (<wsdl:types>)
Add a target namespace declaration to each imported schema in the colleciton:
e.g:
<xsd:import schemaLocation="GetCompetenciesContainer.v1.xsd" namespace="http://www.mywsdlcompany.com/wcf/services/thiswsdlService/2010/01Container" />
becomes
<xsd:import schemaLocation="GetCompetenciesContainer.v1.xsd" namespace="http://www.mywsdlcompany.com/wcf/services/thiswsdlService/2010/01Container" targetNamespace="http://www.mywsdlcompany.com/wcf/services/thiswsdlService/2010/01Container"/>
Finally, add a target namespace declaration to the root schema node as well:
<xsd:schema elementFormDefault="qualified" xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.mywsdlcompany.com/wcf/services/thiswsdlService/2010/01Container">
Save the wsdl file and now use the Visual Studio tool with the wsdl and the downloaded xds files to generate the required bindings
After numerous years of thinking about it, I finally decided to start blogging the errors I documented in scribbles here and there over the years as and when I have the time, in the hope that they'll help some new 'BizTalk-er' to resolve their 'error-under-pressure' scenarios faster
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment