function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AmulAmul 

Getting WSDL Parse Error

Following WSDL i am parsing through WSDL to Apex








<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://tempuri.org" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" targetNamespace="http://tempuri.org">
   <wsdl:types>
      <xs:schema version="1.0">
         <xs:annotation>
            <xs:appinfo>INDSHL</xs:appinfo>
            <xs:documentation xml:lang="en">This is the strategy the wsdl is about</xs:documentation>
         </xs:annotation>
         <!-- Array data type -->
         <xs:simpleType name="DAarray">
            <xs:restriction base="xs:string">
               <xs:enumeration value="array" />
            </xs:restriction>
         </xs:simpleType>
         <!-- Date data type -->
         <xs:complexType name="DAdate">
            <xs:all>
               <xs:element name="value" type="xs:string" />
               <xs:element name="date_format" default="yyyy-MM-dd" minOccurs="0">
                  <xs:simpleType>
                     <xs:restriction base="xs:string">
                        <xs:enumeration value="DDDyyyy" />
                        <xs:enumeration value="ddMMyyyy" />
                        <xs:enumeration value="MMddyyyy" />
                        <xs:enumeration value="yyyy-MM-dd" />
                        <xs:enumeration value="yyyyDDD" />
                        <xs:enumeration value="yyyyddMM" />
                        <xs:enumeration value="yyyyMMdd" />
                     </xs:restriction>
                  </xs:simpleType>
               </xs:element>
            </xs:all>
         </xs:complexType>
         <!-- Numeric data type -->
         <xs:complexType name="DAnumeric">
            <xs:all>
               <xs:element name="value" type="xs:decimal" />
            </xs:all>
         </xs:complexType>
         <!-- String data type -->
         <xs:complexType name="DAstring">
            <xs:all>
               <xs:element name="value" type="xs:string" />
            </xs:all>
         </xs:complexType>
         <!-- DAXMLDocument element -->
         <xs:element name="DAXMLDocument">
            <xs:complexType>
               <xs:all>
                  <!-- OCONTROL data source -->
                  <xs:element name="OCONTROL">
                     <xs:complexType>
                        <xs:all>
                           <xs:element name="ALIAS" type="xs:string" />
                           <xs:element name="SIGNATURE" type="xs:string" />
                           <xs:element name="DALOGLEVEL" minOccurs="0" type="xs:decimal" />
                           <xs:element name="EDITION" minOccurs="0" type="xs:decimal" />
                           <xs:element name="OBJECTIVE" minOccurs="0" type="xs:string" />
                           <xs:element name="EDITIONDATE" minOccurs="0" type="xs:date" />
                           <xs:element name="ERRORCODE" minOccurs="0" type="xs:string" />
                           <xs:element name="ERRORMSG" minOccurs="0" type="xs:string" />
                           <xs:element name="APPLICATION_ID" type="xs:string" />
                        </xs:all>
                     </xs:complexType>
                  </xs:element>
                  <!-- CAMIN data source -->
                  <xs:element minOccurs="0" name="CAMIN">
                     <xs:complexType>
                        <xs:all>
                           <xs:element name="LONUCD001" type="xs:string" nillable="true" />
                           <xs:element name="CACOCD002" type="xs:string" nillable="true" />
                           <xs:element name="APINCD003" type="xs:decimal" nillable="true" />
                           <xs:element name="AGE1CD004" type="xs:decimal" nillable="true" />
                           <xs:element name="APLACD005" type="xs:decimal" nillable="true" />
                           <xs:element name="DSCRCD006" type="xs:decimal" nillable="true" />
                           <xs:element name="FOIRCD007" type="xs:decimal" nillable="true" />
                           <xs:element name="LA01CD008" type="xs:decimal" nillable="true" />
                           <xs:element name="LA02CD009" type="xs:decimal" nillable="true" />
                           <xs:element name="LA03CD010" type="xs:decimal" nillable="true" />
                           <xs:element name="LA04CD011" type="xs:decimal" nillable="true" />
                           <xs:element name="LA05CD012" type="xs:decimal" nillable="true" />
                           <xs:element name="LA06CD013" type="xs:decimal" nillable="true" />
                           <xs:element name="LTV1CD014" type="xs:decimal" nillable="true" />
                           <xs:element name="OCSTCD015" type="xs:decimal" nillable="true" />
                           <xs:element name="PROFCD016" type="xs:string" nillable="true" />
                           <xs:element name="RAHICD017" type="xs:decimal" nillable="true" />
                           <xs:element name="INSOCD018" type="xs:decimal" nillable="true" />
                        </xs:all>
                     </xs:complexType>
                  </xs:element>
                  <!-- CAMOUT data source -->
                  <xs:element minOccurs="0" name="CAMOUT">
                     <xs:complexType>
                        <xs:all>
                           <xs:element name="GEORISKRANKING" type="xs:decimal" nillable="true" />
                           <xs:element name="EXISTINGACTIVELOANS" type="xs:decimal" nillable="true" />
                           <xs:element name="APPSCORE" type="xs:decimal" nillable="true" />
                           <xs:element name="SCORECARDDECISION" type="xs:string" nillable="true" />
                           <xs:element name="SCORECARDVALUE">
                              <xs:complexType>
                                 <xs:all>
                                    <xs:element name="data_type" type="DAarray" />
                                    <xs:element name="I1" type="xs:decimal" nillable="true" />
                                    <xs:element name="I2" type="xs:decimal" nillable="true" />
                                    <xs:element name="I3" type="xs:decimal" nillable="true" />
                                    <xs:element name="I4" type="xs:decimal" nillable="true" />
                                    <xs:element name="I5" type="xs:decimal" nillable="true" />
                                    <xs:element name="I6" type="xs:decimal" nillable="true" />
                                    <xs:element name="I7" type="xs:decimal" nillable="true" />
                                    <xs:element name="I8" type="xs:decimal" nillable="true" />
                                    <xs:element name="I9" type="xs:decimal" nillable="true" />
                                    <xs:element name="I10" type="xs:decimal" nillable="true" />
                                    <xs:element name="I11" type="xs:decimal" nillable="true" />
                                    <xs:element name="I12" type="xs:decimal" nillable="true" />
                                 </xs:all>
                              </xs:complexType>
                           </xs:element>
                           <xs:element name="SCORECARDADVERSEREASONCODE">
                              <xs:complexType>
                                 <xs:all>
                                    <xs:element name="data_type" type="DAarray" />
                                    <xs:element name="I1" type="xs:string" nillable="true" />
                                    <xs:element name="I2" type="xs:string" nillable="true" />
                                    <xs:element name="I3" type="xs:string" nillable="true" />
                                    <xs:element name="I4" type="xs:string" nillable="true" />
                                    <xs:element name="I5" type="xs:string" nillable="true" />
                                    <xs:element name="I6" type="xs:string" nillable="true" />
                                    <xs:element name="I7" type="xs:string" nillable="true" />
                                    <xs:element name="I8" type="xs:string" nillable="true" />
                                    <xs:element name="I9" type="xs:string" nillable="true" />
                                    <xs:element name="I10" type="xs:string" nillable="true" />
                                    <xs:element name="I11" type="xs:string" nillable="true" />
                                    <xs:element name="I12" type="xs:string" nillable="true" />
                                 </xs:all>
                              </xs:complexType>
                           </xs:element>
                        </xs:all>
                     </xs:complexType>
                  </xs:element>
               </xs:all>
            </xs:complexType>
         </xs:element>
      </xs:schema>
   </wsdl:types>
   <wsdl:message name="QueryDARequest">
      <wsdl:part name="queryDA" element="DAXMLDocument" />
   </wsdl:message>
   <wsdl:message name="QueryDAResponse">
      <wsdl:part name="responseDA" element="DAXMLDocument" />
   </wsdl:message>
   <wsdl:portType name="QueryDA">
      <wsdl:operation name="queryDA">
         <wsdl:input message="tns:QueryDARequest" />
         <wsdl:output message="tns:QueryDAResponse" />
      </wsdl:operation>
   </wsdl:portType>
   <wsdl:binding name="QueryDASoap" type="tns:QueryDA">
      <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" />
      <wsdl:operation name="queryDA">
         <soap:operation soapAction="" />
         <wsdl:input>
            <soap:body use="literal" />
         </wsdl:input>
         <wsdl:output>
            <soap:body use="literal" />
         </wsdl:output>
      </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="QueryDAService">
      <wsdl:port name="QueryDASoap" binding="tns:QueryDASoap">
         <soap:address location="https://indiacert.pcomanagedservice.com/DAService" />
      </wsdl:port>
   </wsdl:service>
</wsdl:definitions>






getting following error

Error: Failed to parse wsdl: Parse error: Found invalid XML. only whitespace content allowed before start tag and not \ufffd (position: START_DOCUMENT seen \ufffd... @1:1)


Please help
SandhyaSandhya (Salesforce Developers) 
Hi,

Use Save As of browser to download Partner WSDL, and you can choose .wsdl or xml type to save the wsdl file.

Don't just copy the source file to process.

And then use eclipse to import the Partner WSDL.


Hope this helps you!

Please mark it as Best Answer if my reply was helpful. It will make it available for other as the proper solution.
 
Thanks and Regards
Sandhya