Loading ...
Sorry, an error occurred while loading the content.

HELP: .NET dropping variables for methods.

Expand Messages
  • jedijay007
    I am using soap::lite to call .NET methods, all of a sudden .NET will not pickup any of the variables I pass to it. If I call a method with no variables it
    Message 1 of 1 , Dec 20, 2005
    • 0 Attachment
      I am using soap::lite to call .NET methods, all of a sudden .NET will
      not pickup any of the variables I pass to it. If I call a method with
      no variables it returns just fine, otherwise it spits back an error
      saying that variable foo is required.

      Here is my code:
      ###########################################################3
      my $ns = "http://www.1234.com"; ##this should NOT end with a /
      my $url = "http://123.123.123.123/test.asmx";

      my ($soap, $result, $output);
      $soap = SOAP::Lite
      -> uri($ns)
      -> on_action( sub { join '/', $ns, $_[1] })
      -> proxy ($url);

      my $method = SOAP::Data->name('HelloWorldEcho')->attr( {xmlns => $ns});
      my @params = (
      SOAP::Data->name('schema')->value('schema string')->type(''),
      SOAP::Data->name('deployment')->value('deployment string')->type(''),
      SOAP::Data->name('session')->value('session string')->type(''),
      SOAP::Data->name('input')->value('input string')->type('')
      );

      my $test = $soap->call($method => @params);
      if ($test->fault) {
      print "faultcode = " . $test->faultcode .
      "<br> faultstring = " . $test->faultstring .
      "<br> faultactor = " . $test->faultactor .
      "<br> faultdetail = " . $test->faultdetail;
      } else {
      print "the result is: " . $test->result;
      }

      #####################################################
      There aren't any faults, it's just that the method doesn't recognize
      that I passed it any variables. With debugging on here is my request
      header:

      #####################################################
      POST http://172.20.120.120/prissmwebinterface/prissmweb.asmx
      Accept: text/xml
      Accept: multipart/*
      Content-Length: 585
      Content-Type: text/xml; charset=utf-8
      SOAPAction: http://www.ppdi.com/HelloWorldEcho

      <?xml version="1.0" encoding="UTF-8"?>
      <SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
      xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
      xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
      xmlns:xsd="http://www.w3.org/1999/XMLSchema"
      SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
      <SOAP-ENV:Body>
      <HelloWorldEcho xmlns="http://www.ppdi.com">
      <schema>schema string</schema>
      <deployment>deployment string</deployment>
      <session>session string</session>
      <input>input string</input>
      </HelloWorldEcho>
      </SOAP-ENV:Body>
      </SOAP-ENV:Envelope>
      ################################################################

      ANY HELP/SUGGESTIONS WOULD BE GREATLY APPRECIATED!!!!

      THANKS IN ADVANCE,
      JAY
    Your message has been successfully submitted and would be delivered to recipients shortly.