<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head>
<body bgcolor="#ffffff" text="#000000">
Hi Guys<br>
<br>
I had imported a WSDL file and built a soap service to send data to a
web service. Unfortunately there is a bug in the WSDL that impacts
delphi but seems to be ignored in Microsoft tools (it really is a
problem with the wsdl file). Anyway since it is a simple job I thought
it might be quicker to fix by just removing the soap and building the
XML manually and posting it with idHttp. <br>
<br>
However I cant get it to work ! When I try and post my test xml to the
web serivce I get an 'Invalid IOHandler' message in the app. I have no
ioHandler defined but that works fine in my other apps where I post to
php based web services. I am sure it is just some weird indy bug but I
am under a huge deadline and need to sort this. Any help would be
greatly appreciated.<br>
<br>
code follows (this is quick and dirty proof of concept code)<br>
<br>
var<br>
sl : TStringList;<br>
PostDataStream : TStringStream;<br>
SendStream : TStringStream;<br>
begin<br>
PostDataStream := TStringStream.Create('');<br>
sl := TStringList.Create;<br>
try<br>
IdHTTP.Request.Username := '9313527067946306';<br>
IdHTTP.Request.Password := 'passdfsw9634306';<br>
IdHTTP.ReadTimeout := 5000;<br>
<br>
sl.LoadFromFile('E:\Work\Test post\TestRequest.XML');<br>
SendStream := TStringStream.Create(sl.text);<br>
<br>
<br>
IdHTTP.Post('<a class="moz-txt-link-freetext" href="https://uateclonline.nzpost.co.nz/eclonlinewebnowse/Services.asmx">https://uateclonline.nzpost.co.nz/eclonlinewebnowse/Services.asmx</a>',
SendStream, PostDataStream); //Error here <br>
<br>
ShowMessage(PostDataStream.DataString);<br>
finally<br>
sl.Free;<br>
PostDataStream.Free;<br>
SendStream.Free;<br>
end;<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<div class="moz-signature">-- <br>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<meta name="ProgId" content="Word.Document">
<meta name="Generator" content="Microsoft Word 11">
<meta name="Originator" content="Microsoft Word 11">
<link rel="File-List" href="Robert%20Martin_files/filelist.xml">
<title>Robert Martin</title>
<!--[if gte mso 9]><xml>
<o:DocumentProperties>
<o:Author>Wild Software Ltd</o:Author>
<o:LastAuthor>Wild Software Ltd</o:LastAuthor>
<o:Revision>6</o:Revision>
<o:TotalTime>55</o:TotalTime>
<o:Created>2009-02-13T02:47:00Z</o:Created>
<o:LastSaved>2009-02-13T03:42:00Z</o:LastSaved>
<o:Pages>1</o:Pages>
<o:Words>13</o:Words>
<o:Characters>77</o:Characters>
<o:Company>Wild Software Ltd</o:Company>
<o:Lines>1</o:Lines>
<o:Paragraphs>1</o:Paragraphs>
<o:CharactersWithSpaces>89</o:CharactersWithSpaces>
<o:Version>11.9999</o:Version>
</o:DocumentProperties>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:WordDocument>
<w:SpellingState>Clean</w:SpellingState>
<w:GrammarState>Clean</w:GrammarState>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
</w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" LatentStyleCount="156">
</w:LatentStyles>
</xml><![endif]-->
<style>
<!--
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {mso-style-parent:"";
        margin:0cm;
        margin-bottom:.0001pt;
        mso-pagination:widow-orphan;
        font-size:12.0pt;
        font-family:"Times New Roman";
        mso-fareast-font-family:"Times New Roman";}
span.SpellE
        {mso-style-name:"";
        mso-spl-e:yes;}
@page Section1
        {size:595.3pt 841.9pt;
        margin:72.0pt 90.0pt 72.0pt 90.0pt;
        mso-header-margin:35.4pt;
        mso-footer-margin:35.4pt;
        mso-paper-source:0;}
div.Section1
        {page:Section1;}
-->
</style><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
        {mso-style-name:"Table Normal";
        mso-tstyle-rowband-size:0;
        mso-tstyle-colband-size:0;
        mso-style-noshow:yes;
        mso-style-parent:"";
        mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
        mso-para-margin:0cm;
        mso-para-margin-bottom:.0001pt;
        mso-pagination:widow-orphan;
        font-size:10.0pt;
        font-family:"Times New Roman";
        mso-ansi-language:#0400;
        mso-fareast-language:#0400;
        mso-bidi-language:#0400;}
</style>
<![endif]-->
<div class="Section1">
<p class="MsoNormal"><i style=""><span
style="font-size: 10pt; font-family: Arial;" lang="EN-NZ">Robert Martin<o:p></o:p></span></i></p>
<p class="MsoNormal"><i style=""><span
style="font-size: 10pt; font-family: Arial;" lang="EN-NZ">Software
development
manager<o:p></o:p></span></i></p>
<p class="MsoNormal"><span style="font-size: 10pt; font-family: Arial;"
lang="EN-NZ"><o:p> </o:p></span></p>
<p class="MsoNormal"><span class="SpellE"><span
style="font-size: 10pt; font-family: Arial;" lang="EN-NZ">Chreos</span></span><span
style="font-size: 10pt; font-family: Arial;" lang="EN-NZ"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size: 10pt; font-family: Arial;"
lang="EN-NZ"><a class="moz-txt-link-abbreviated" href="http://www.chreos.co.nz">www.chreos.co.nz</a><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size: 10pt; font-family: Arial;"
lang="EN-NZ">Ph +64 03 377-0495<o:p></o:p></span></p>
<p class="MsoNormal"><span style="" lang="EN-NZ"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(255, 153, 0);" lang="EN-NZ"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="" lang="EN-NZ"><o:p> </o:p></span></p>
</div>
</div>
</body>
</html>