title: Android ksoap2 i:type suppression
body: <p>I am trying to figure out how to suppress the i:type tag in the xml output generated by the ksoap2 library. I have tried the answers given in other posts but they have not worked. Does anyone have any ideas?</p>
  
  <pre><code>public static SoapObject createRequest() {
  
      SoapObject method = new SoapObject(WS_NAMESPACE, WS_METHOD_NAME);
      SoapObject request = new SoapObject("", "Request");
  
      //Create source credentials object
      SoapObject sourceCredentials = new SoapObject("", "SourceCredentials");
  
      PropertyInfo sourceNameProp = new PropertyInfo();
      //sourceNameProp.setNamespace(WS_NAMESPACE);
      sourceNameProp.setName("SourceName");
      sourceNameProp.setValue(SOURCENAME);
  
      PropertyInfo passwordProp = new PropertyInfo();
      //passwordProp.setNamespace(WS_NAMESPACE);
      passwordProp.setName("Password");
      passwordProp.setValue(PASSWORD);
  
      sourceCredentials.addProperty(sourceNameProp);
      sourceCredentials.addProperty(passwordProp);
  
      SoapObject siteIds = new SoapObject("","SiteIDs");
  
      PropertyInfo siteIDProp = new PropertyInfo();
      //siteIDProp.setNamespace(WS_NAMESPACE);
      siteIDProp.setName("int");
      siteIDProp.setValue(SITE_IDS);
  
      siteIds.addProperty(siteIDProp);
  
      sourceCredentials.addSoapObject(siteIds);
      request.addSoapObject(sourceCredentials);
  
      PropertyInfo xMLDetailProp = new PropertyInfo();
      //xMLDetailProp.setNamespace(WS_NAMESPACE);
      xMLDetailProp.setName("XMLDetail");
      xMLDetailProp.setValue("Full");
  
      PropertyInfo pageSizeProp = new PropertyInfo();
      //pageSizeProp.setNamespace(WS_NAMESPACE);
      pageSizeProp.setName("PageSize");
      pageSizeProp.setValue("10");
  
      PropertyInfo curPageProp = new PropertyInfo();
      //curPageProp.setNamespace(WS_NAMESPACE);
      curPageProp.setName("CurrentPageIndex");
      curPageProp.setValue("0");
  
      request.addProperty(xMLDetailProp);
      request.addProperty(pageSizeProp);
      request.addProperty(curPageProp);
  
      method.addSoapObject(request);
  
      return method;
  }
  </code></pre>
  
  <p>Then we create the envelope using code snippet below:</p>
  
  <pre><code>    // 1. Create SOAP Envelope using the request
      SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
      envelope.dotNet = true;
      envelope.implicitTypes = true;
      envelope.setAddAdornments(false);
  
      envelope.setOutputSoapObject(parameter);
  
      // 2. Create a HTTP Transport object to send the web service request
      HttpTransportSE httpTransport = new HttpTransportSE(WSDL_URL);
      httpTransport.debug = true; // allows capture of raw request/response in Logcat
  
      // 3. Make the web service invocation
      httpTransport.call(WS_NAMESPACE + "/" + WS_METHOD_NAME, envelope);
  </code></pre>
  
  <p>Output XML is below. Problem is the web service does not like the i:type fields on the Request and SourceCredentials nodes and I can't figure out how to suppress them. Can someone please help? Thanks.</p>
  
  <pre><code>    &lt;v:Envelope xmlns:i="http://www.w3.org/1999/XMLSchema-instance" xmlns:d="http://www.w3.org/1999/XMLSchema" xmlns:c="http://schemas.xmlsoap.org/soap/encoding/" xmlns:v="http://schemas.xmlsoap.org/soap/envelope/"&gt;&lt;v:Header /&gt;
    &lt;v:Body&gt;
      &lt;GetLocations xmlns="http://clients.mindbodyonline.com/api/0_5"&gt;
        &lt;Request i:type=":Request"&gt;
          &lt;SourceCredentials i:type=":SourceCredentials"&gt;
            &lt;SourceName i:type="d:string"&gt;PilatesonCollins&lt;/SourceName&gt;
            &lt;Password i:type="d:string"&gt;XGn2PaLeRoD8qoDtrZfODu8j71c=&lt;/Password&gt;
            &lt;SiteIDs i:type=":SiteIDs"&gt;
              &lt;int i:type="d:int"&gt;25755&lt;/int&gt;
            &lt;/SiteIDs&gt;
          &lt;/SourceCredentials&gt;
          &lt;XMLDetail i:type="d:string"&gt;Full&lt;/XMLDetail&gt;
          &lt;PageSize i:type="d:string"&gt;10&lt;/PageSize&gt;
          &lt;CurrentPageIndex i:type="d:string"&gt;0&lt;/CurrentPageIndex&gt;
        &lt;/Request&gt;
      &lt;/GetLocations&gt;
    &lt;/v:Body&gt;
  &lt;/v:Envelope&gt;
  </code></pre>