Hi

I am trying to convert some VB code into Perl Lite. It is simply taking some XML (within the strPayload) for processing.

My VB Code is ..
Dim Serializer As SoapSerializer30 Dim reader As SoapReader30 Dim Connector As SoapConnector30
'Target for soap message Const END_POINT_URL = "http://wdb_sqltest:8080/ssc/servlet/SUGSoap" Set Connector = CreateObject("MSSOAP.HttpConnector30") Set Serializer = CreateObject("MSSOAP.SoapSerializer30") Set reader = CreateObject("MSSOAP.SoapReader30") Connector.Property("EndPointURL") = END_POINT_URL Connector.Connect Connector.Property("SoapAction") = "uri:SystemUnion-Journal" Connector.BeginMessage Serializer.Init Connector.InputStream Serializer.StartEnvelope Serializer.SoapNamespace "xsi", "http://www.w3.org/1999/XMLSchema- +instance" Serializer.StartBody Serializer.startElement "Import","SystemUnion-Journal", , "m" Serializer.startElement "strPayload" Serializer.SoapAttribute "xsi:type", "", "xsd:string" Serializer.WriteString strPayload Serializer.endElement Serializer.endElement Serializer.EndBody Serializer.EndEnvelope Connector.EndMessage

I have got as far as the following, but cannot see how I pass in the XML and call a method to run it !!!

use SOAP::Lite; my ($soap); $soap = new SOAP::Lite; $soap->transport->proxy('http://wdb_sqltest:8080/ssc/servlet/SUGSoap') +; $soap->serializer->uri('http://www.w3.org/1999/XMLSchema-instance'); $soap->serializer->envprefix('xsi'); $soap->call(SOAP::Data->name('Import') ->attr({xmlns=>'xsi'}) => 'uri: +SystemUnion-Journal');

In total confusion
Dave

janitored by ybiC: Retitle from "SOAP::Lite" because one-word nodetitles hinder site search


In reply to Convert VB code to perl and SOAP::Lite by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.