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
Gonzalo Quevedo 15Gonzalo Quevedo 15 

wsdl2Apex namespace error

Hi!, 

Salesforce is encountering problems parsing XML response from a WS, all indicates that is a problem with something relative to namespace. Response looks like:

<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <soapenv:Header />
   <soapenv:Body>
      <p788:altaCuentaResponse xmlns:p788="http://urlgoeshere">
         <altaCuentaReturn>
            <codigoError>2001</codigoError>
            <mensajeError>error.</mensajeError>
            <resultadoOperacion>ERROR</resultadoOperacion>
            <codigoCuenta xsi:nil="true" />
         </altaCuentaReturn>
      </p788:altaCuentaResponse>
   </soapenv:Body>
</soapenv:Envelope>

Salesforce can't parse this strange prefix "788" .

Is there any way to modify wsdl2apex generated class to solve this problem?  Any idea? I've tried to import wsdl using fuse app and I'm able to parse response body but I think it's not the best solution. 

Thank you!