Re: [twsocket] Using TWSocket
> Thank you so much for all your patience and an excellent product. You welcome. In french, we have a proverb saying (Free translation): "Only those who don't work, don't do errors". -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be - Original Message - From: "Hein du Plessis" <[EMAIL PROTECTED]> To: "'ICS support mailing'" Sent: Friday, August 15, 2008 5:06 PM Subject: Re: [twsocket] Using TWSocket > Francois I am terribly embarressed! Through a combination of type and > variable errors I missed the obvious. > > WSocket.Send(@Size,2) works indeed. > > Thank you so much for all your patience and an excellent product. > > Regards, > Hein > > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf Of Francois PIETTE > Sent: 15 August 2008 16:20 > To: ICS support mailing > Subject: Re: [twsocket] Using TWSocket > >> Size: Word; >> p:= @Size; >> WSocket.Send(Size,2); // THIS IS THE PROBLEM. IT WORKS IF I NOW USE P >> as > > Send takes a pointer as first parameter. You are passing an integer ! That > is what the compiler telling you when it says "There is no overloaded > version of "Send" that can be called with these arguments." > > Use WSocket.Send(@Size, SizeOf(Size)); > > btw: This is really not an issue with ICS but just Delphi syntax and > compiler error understanding... > > -- > [EMAIL PROTECTED] > The author of the freeware multi-tier middleware MidWare The author of the > freeware Internet Component Suite (ICS) http://www.overbyte.be > > > - Original Message - > From: "Hein du Plessis" <[EMAIL PROTECTED]> > To: "'ICS support mailing'" > Sent: Friday, August 15, 2008 3:08 PM > Subject: Re: [twsocket] Using TWSocket > > >> Hi There >> >> Here is the entire routine: >> >> procedure TfrmMain.btnRequestClick(Sender: TObject); >> var XMLData: TStringStream; >> SizeData: TMemoryStream; >> Msg: String; >> Size: Word; >> p: TWSocketData; >> begin >> {Package and send} >> Msg:= >> BuildVendRequest(edSeq.Value,edReference.Text,114.50,'0100032'); >> XMLData := TStringStream.Create(Msg); >> SizeData:= TMemoryStream.Create; >> Size:= length (Msg); >> Size:= Swap(Size); >> p:= @Size; >> >> LogMessage('Sending Request...'); >> >> WSocket.BufSize:= 2; >> p:= @Size; >> WSocket.Send(Size,2); // THIS IS THE PROBLEM. IT WORKS IF I NOW USE P as >> the parameter. >> WSocket.SendStr(Msg); >> >> XMLData.Free; >> SizeData.Free; >> end; >> >> Just change >> >> -Original Message- >> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On >> Behalf Of Francois PIETTE >> Sent: 15 August 2008 12:23 >> To: ICS support mailing >> Subject: Re: [twsocket] Using TWSocket >> >>> The error I received was "There is no overloaded version of "Send" >>> that can be called with these arguments. >>> >>> This is when I try to send a variable of type word. The @ prefix did >>> not work either. >> >> Would be REALLY interesting to see the offending line ! >> >>> I'm using Delphi 2007 Version 11.0.2804.9245 I'm not sure if there are >>> further updates available. >> >> This is an old version. Latest is 11.0.2902.10471 See >> http://cc.codegear.com/reg/delphi and download/install everything ! >> >> -- >> [EMAIL PROTECTED] >> The author of the freeware multi-tier middleware MidWare The author of >> the >> freeware Internet Component Suite (ICS) http://www.overbyte.be >> >> -- >> To unsubscribe or change your settings for TWSocket mailing list please >> goto >> http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket >> Visit our website at http://www.overbyte.be >> >> >> -- >> To unsubscribe or change your settings for TWSocket mailing list >> please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket >> Visit our website at http://www.overbyte.be > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be > > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
Francois I am terribly embarressed! Through a combination of type and variable errors I missed the obvious. WSocket.Send(@Size,2) works indeed. Thank you so much for all your patience and an excellent product. Regards, Hein -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Francois PIETTE Sent: 15 August 2008 16:20 To: ICS support mailing Subject: Re: [twsocket] Using TWSocket > Size: Word; > p:= @Size; > WSocket.Send(Size,2); // THIS IS THE PROBLEM. IT WORKS IF I NOW USE P > as Send takes a pointer as first parameter. You are passing an integer ! That is what the compiler telling you when it says "There is no overloaded version of "Send" that can be called with these arguments." Use WSocket.Send(@Size, SizeOf(Size)); btw: This is really not an issue with ICS but just Delphi syntax and compiler error understanding... -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be - Original Message - From: "Hein du Plessis" <[EMAIL PROTECTED]> To: "'ICS support mailing'" Sent: Friday, August 15, 2008 3:08 PM Subject: Re: [twsocket] Using TWSocket > Hi There > > Here is the entire routine: > > procedure TfrmMain.btnRequestClick(Sender: TObject); > var XMLData: TStringStream; > SizeData: TMemoryStream; > Msg: String; > Size: Word; > p: TWSocketData; > begin > {Package and send} > Msg:= > BuildVendRequest(edSeq.Value,edReference.Text,114.50,'0100032'); > XMLData := TStringStream.Create(Msg); > SizeData:= TMemoryStream.Create; > Size:= length (Msg); > Size:= Swap(Size); > p:= @Size; > > LogMessage('Sending Request...'); > > WSocket.BufSize:= 2; > p:= @Size; > WSocket.Send(Size,2); // THIS IS THE PROBLEM. IT WORKS IF I NOW USE P as > the parameter. > WSocket.SendStr(Msg); > > XMLData.Free; > SizeData.Free; > end; > > Just change > > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf Of Francois PIETTE > Sent: 15 August 2008 12:23 > To: ICS support mailing > Subject: Re: [twsocket] Using TWSocket > >> The error I received was "There is no overloaded version of "Send" >> that can be called with these arguments. >> >> This is when I try to send a variable of type word. The @ prefix did >> not work either. > > Would be REALLY interesting to see the offending line ! > >> I'm using Delphi 2007 Version 11.0.2804.9245 I'm not sure if there are >> further updates available. > > This is an old version. Latest is 11.0.2902.10471 See > http://cc.codegear.com/reg/delphi and download/install everything ! > > -- > [EMAIL PROTECTED] > The author of the freeware multi-tier middleware MidWare The author of the > freeware Internet Component Suite (ICS) http://www.overbyte.be > > -- > To unsubscribe or change your settings for TWSocket mailing list please > goto > http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be > > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
> Size: Word; > p:= @Size; > WSocket.Send(Size,2); // THIS IS THE PROBLEM. IT WORKS IF I NOW USE P as Send takes a pointer as first parameter. You are passing an integer ! That is what the compiler telling you when it says "There is no overloaded version of "Send" that can be called with these arguments." Use WSocket.Send(@Size, SizeOf(Size)); btw: This is really not an issue with ICS but just Delphi syntax and compiler error understanding... -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be - Original Message - From: "Hein du Plessis" <[EMAIL PROTECTED]> To: "'ICS support mailing'" Sent: Friday, August 15, 2008 3:08 PM Subject: Re: [twsocket] Using TWSocket > Hi There > > Here is the entire routine: > > procedure TfrmMain.btnRequestClick(Sender: TObject); > var XMLData: TStringStream; > SizeData: TMemoryStream; > Msg: String; > Size: Word; > p: TWSocketData; > begin > {Package and send} > Msg:= > BuildVendRequest(edSeq.Value,edReference.Text,114.50,'0100032'); > XMLData := TStringStream.Create(Msg); > SizeData:= TMemoryStream.Create; > Size:= length (Msg); > Size:= Swap(Size); > p:= @Size; > > LogMessage('Sending Request...'); > > WSocket.BufSize:= 2; > p:= @Size; > WSocket.Send(Size,2); // THIS IS THE PROBLEM. IT WORKS IF I NOW USE P as > the parameter. > WSocket.SendStr(Msg); > > XMLData.Free; > SizeData.Free; > end; > > Just change > > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf Of Francois PIETTE > Sent: 15 August 2008 12:23 > To: ICS support mailing > Subject: Re: [twsocket] Using TWSocket > >> The error I received was "There is no overloaded version of "Send" >> that can be called with these arguments. >> >> This is when I try to send a variable of type word. The @ prefix did >> not work either. > > Would be REALLY interesting to see the offending line ! > >> I'm using Delphi 2007 Version 11.0.2804.9245 I'm not sure if there are >> further updates available. > > This is an old version. Latest is 11.0.2902.10471 See > http://cc.codegear.com/reg/delphi and download/install everything ! > > -- > [EMAIL PROTECTED] > The author of the freeware multi-tier middleware MidWare The author of the > freeware Internet Component Suite (ICS) http://www.overbyte.be > > -- > To unsubscribe or change your settings for TWSocket mailing list please > goto > http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be > > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
Hi, Yes in the mean time I've adjusted the code, please see previous email. Regards, Hein -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Francois PIETTE Sent: 15 August 2008 14:09 To: ICS support mailing Subject: Re: [twsocket] Using TWSocket >> The error I received was "There is no overloaded version of "Send" >> that can be called with these arguments. >> >> This is when I try to send a variable of type word. The @ prefix did >> not work either. >> WSocket.BufSize:= 2; >> p:= @Size; >> WSocket.Send(p); TWSocket.Send require two arguments: 1) A pointer to the data 2) The number of bytes to send Write like this WSocket.Send(@Size, SizeOf(Size)); // or Length(Size) depending on what Size is. >> WSocket.BufSize:= 2; BufSize is the size of TWSocket send buffer. Do not change it unless you understand what the purpose is. The default value is best for sending over Ethernet because it correspond to the maximum data size of an Ethernet packet. -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
Hi There Here is the entire routine: procedure TfrmMain.btnRequestClick(Sender: TObject); var XMLData: TStringStream; SizeData: TMemoryStream; Msg: String; Size: Word; p: TWSocketData; begin {Package and send} Msg:= BuildVendRequest(edSeq.Value,edReference.Text,114.50,'0100032'); XMLData := TStringStream.Create(Msg); SizeData:= TMemoryStream.Create; Size:= length (Msg); Size:= Swap(Size); p:= @Size; LogMessage('Sending Request...'); WSocket.BufSize:= 2; p:= @Size; WSocket.Send(Size,2); // THIS IS THE PROBLEM. IT WORKS IF I NOW USE P as the parameter. WSocket.SendStr(Msg); XMLData.Free; SizeData.Free; end; Just change -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Francois PIETTE Sent: 15 August 2008 12:23 To: ICS support mailing Subject: Re: [twsocket] Using TWSocket > The error I received was "There is no overloaded version of "Send" > that can be called with these arguments. > > This is when I try to send a variable of type word. The @ prefix did > not work either. Would be REALLY interesting to see the offending line ! > I'm using Delphi 2007 Version 11.0.2804.9245 I'm not sure if there are > further updates available. This is an old version. Latest is 11.0.2902.10471 See http://cc.codegear.com/reg/delphi and download/install everything ! -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
>> The error I received was "There is no overloaded version of "Send" that >> can >> be called with these arguments. >> >> This is when I try to send a variable of type word. The @ prefix did not >> work either. >> WSocket.BufSize:= 2; >> p:= @Size; >> WSocket.Send(p); TWSocket.Send require two arguments: 1) A pointer to the data 2) The number of bytes to send Write like this WSocket.Send(@Size, SizeOf(Size)); // or Length(Size) depending on what Size is. >> WSocket.BufSize:= 2; BufSize is the size of TWSocket send buffer. Do not change it unless you understand what the purpose is. The default value is best for sending over Ethernet because it correspond to the maximum data size of an Ethernet packet. -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
> Would be REALLY interesting to see the offending line ! He gave it in an earlier message, only one parameter so clearly an error, and not pointing to any data either but the size, and corrupting the main buffer: WSocket.BufSize:= 2; p:= @Size; WSocket.Send(p); Angus -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
> The error I received was "There is no overloaded version of "Send" that > can > be called with these arguments. > > This is when I try to send a variable of type word. The @ prefix did not > work either. Would be REALLY interesting to see the offending line ! > I'm using Delphi 2007 Version 11.0.2804.9245 > I'm not sure if there are further updates available. This is an old version. Latest is 11.0.2902.10471 See http://cc.codegear.com/reg/delphi and download/install everything ! -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
The error I received was "There is no overloaded version of "Send" that can be called with these arguments. This is when I try to send a variable of type word. The @ prefix did not work either. I'm using Delphi 2007 Version 11.0.2804.9245 I'm not sure if there are further updates available. Regards, Hein -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Francois PIETTE Sent: 15 August 2008 11:43 To: ICS support mailing Subject: Re: [twsocket] Using TWSocket > I declared p as TWSocketData, assigned my data to it and Send sends it > perfectly! Strange that I cant use my data straight in the send method > (I get the type mismatch error). Please post your code snippet here, and the exact error message. Which Delphi version are you using ? Are you sure you installed all service packs for Delphi ? -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
> I declared p as TWSocketData, assigned my data to it and Send sends it > perfectly! Strange that I cant use my data straight in the send method (I > get the type mismatch error). Please post your code snippet here, and the exact error message. Which Delphi version are you using ? Are you sure you installed all service packs for Delphi ? -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] Using TWSocket
Thanks Francois I declared p as TWSocketData, assigned my data to it and Send sends it perfectly! Strange that I cant use my data straight in the send method (I get the type mismatch error). Thanks again! Regards, Hein -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Francois PIETTE Sent: 15 August 2008 09:03 To: ICS support mailing Subject: Re: [twsocket] Using TWSocket >I have tried to ctrl+click to find the delcaration, but it would not. Have you tried CTRL+SHFT+F (Find in files) ? This always work ! TWSocketData is defined in WSockBuf.pas like this: TWSocketData = type Pointer; If you need to use it in you own application, just add OverbyteIcsWSockBuf in your uses clause. You can cast Sample code (Not real code, just to show syntax examples): procedure TForm3.Button1Click(Sender: TObject); var Buf1 : array [0..1023] of char; Buf2 : Integer; Buf3 : PChar; begin WSocket1.Send(@Buf1, SizeOf(Buf1)); // Send 1024 bytes WSocket1.Send(@Buf2, SizeOf(Buf2)); // send the 4 bytes of the integer WSocket1.Send(Buf3, 123);// Send 123 chars pointed by Buf3 end; -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be - Original Message - From: "Hein du Plessis" <[EMAIL PROTECTED]> To: "'ICS support mailing'" Sent: Friday, August 15, 2008 8:08 AM Subject: Re: [twsocket] Using TWSocket >I have tried to ctrl+click to find the delcaration, but it would not. > > Can somebody perhaps point me to a sample using send? > > Thanks again, > Hein > > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf Of Francois PIETTE > Sent: 14 August 2008 20:02 > To: ICS support mailing > Subject: Re: [twsocket] Using TWSocket > >>functionSend(const Data : TWSocketData; Len : Integer) : Integer; >> overload; virtual; >> >> What is TWSocketData ?? > > In Delphi, your CTRL+Click on the symbol to find the definition. > Find in files also work nice. > > -- > [EMAIL PROTECTED] > The author of the freeware multi-tier middleware MidWare The author of the > freeware Internet Component Suite (ICS) http://www.overbyte.be > > > - Original Message - > From: "Hein du Plessis" <[EMAIL PROTECTED]> > To: "'ICS support mailing'" > Sent: Thursday, August 14, 2008 6:38 PM > Subject: Re: [twsocket] Using TWSocket > > >> Just another note, the declaration of Send is: >> >>functionSend(const Data : TWSocketData; Len : Integer) : Integer; >> overload; virtual; >> >> What is TWSocketData ?? >> >> Thanks! >> >> -Original Message- >> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On >> Behalf Of brian >> Sent: 14 August 2008 18:08 >> To: ICS support mailing >> Subject: Re: [twsocket] Using TWSocket >> >> Then you can either use .send with a memory pointer or load the entire >> xml >> into a string >> >> - Original Message - >> From: "Hein du Plessis" <[EMAIL PROTECTED]> >> To: "'ICS support mailing'" >> Sent: Thursday, August 14, 2008 5:44 PM >> Subject: Re: [twsocket] Using TWSocket >> >> >>> Thanks Brian >>> >>> Unfortunately the application on the server requires a binary length >>> indicator first, followed by XML. The XML part is easy with the SendStr >>> function. >>> >>> Thanks, >>> Hein >>> >>> -Original Message- >>> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] >>> On >>> Behalf Of brian >>> Sent: 14 August 2008 17:29 >>> To: ICS support mailing >>> Subject: Re: [twsocket] Using TWSocket >>> >>> you can use SendStr to send a simple text >>> >>> - Original Message - >>> From: "Hein du Plessis" <[EMAIL PROTECTED]> >>> To: >>> Sent: Thursday, August 14, 2008 4:59 PM >>> Subject: [twsocket] Using TWSocket >>> >>> Hi All I'm trying to write a simple TCP/IP app but I'm not sure how to actually send data. The Send Method of ICS v6 requires a data type TWSocketData, yet the documentation states it needs a pointer. On the ICS page there is mention of a sample app, Client5, that would probably solve my problem, but I'm unable to find it in the download package of ICS V6. This is for Delphi. Any help appreciated! Thanks, Hein -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be >>> >>> -- >>> To unsubscribe or change your settings for TWSocket mailing list >>> please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket >>> Visit our website at http://www.overbyte.be >>> >>> >>> -- >>> To unsubscribe or change your settings for TWSocket mailing list >>> please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket >>> Visit our website at http://www.overbyte.be >> >> -- >> To unsubscribe or change you
Re: [twsocket] Using TWSocket
>I have tried to ctrl+click to find the delcaration, but it would not. Have you tried CTRL+SHFT+F (Find in files) ? This always work ! TWSocketData is defined in WSockBuf.pas like this: TWSocketData = type Pointer; If you need to use it in you own application, just add OverbyteIcsWSockBuf in your uses clause. You can cast Sample code (Not real code, just to show syntax examples): procedure TForm3.Button1Click(Sender: TObject); var Buf1 : array [0..1023] of char; Buf2 : Integer; Buf3 : PChar; begin WSocket1.Send(@Buf1, SizeOf(Buf1)); // Send 1024 bytes WSocket1.Send(@Buf2, SizeOf(Buf2)); // send the 4 bytes of the integer WSocket1.Send(Buf3, 123);// Send 123 chars pointed by Buf3 end; -- [EMAIL PROTECTED] The author of the freeware multi-tier middleware MidWare The author of the freeware Internet Component Suite (ICS) http://www.overbyte.be - Original Message - From: "Hein du Plessis" <[EMAIL PROTECTED]> To: "'ICS support mailing'" Sent: Friday, August 15, 2008 8:08 AM Subject: Re: [twsocket] Using TWSocket >I have tried to ctrl+click to find the delcaration, but it would not. > > Can somebody perhaps point me to a sample using send? > > Thanks again, > Hein > > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf Of Francois PIETTE > Sent: 14 August 2008 20:02 > To: ICS support mailing > Subject: Re: [twsocket] Using TWSocket > >>functionSend(const Data : TWSocketData; Len : Integer) : Integer; >> overload; virtual; >> >> What is TWSocketData ?? > > In Delphi, your CTRL+Click on the symbol to find the definition. > Find in files also work nice. > > -- > [EMAIL PROTECTED] > The author of the freeware multi-tier middleware MidWare The author of the > freeware Internet Component Suite (ICS) http://www.overbyte.be > > > - Original Message - > From: "Hein du Plessis" <[EMAIL PROTECTED]> > To: "'ICS support mailing'" > Sent: Thursday, August 14, 2008 6:38 PM > Subject: Re: [twsocket] Using TWSocket > > >> Just another note, the declaration of Send is: >> >>functionSend(const Data : TWSocketData; Len : Integer) : Integer; >> overload; virtual; >> >> What is TWSocketData ?? >> >> Thanks! >> >> -Original Message- >> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On >> Behalf Of brian >> Sent: 14 August 2008 18:08 >> To: ICS support mailing >> Subject: Re: [twsocket] Using TWSocket >> >> Then you can either use .send with a memory pointer or load the entire >> xml >> into a string >> >> - Original Message - >> From: "Hein du Plessis" <[EMAIL PROTECTED]> >> To: "'ICS support mailing'" >> Sent: Thursday, August 14, 2008 5:44 PM >> Subject: Re: [twsocket] Using TWSocket >> >> >>> Thanks Brian >>> >>> Unfortunately the application on the server requires a binary length >>> indicator first, followed by XML. The XML part is easy with the SendStr >>> function. >>> >>> Thanks, >>> Hein >>> >>> -Original Message- >>> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] >>> On >>> Behalf Of brian >>> Sent: 14 August 2008 17:29 >>> To: ICS support mailing >>> Subject: Re: [twsocket] Using TWSocket >>> >>> you can use SendStr to send a simple text >>> >>> - Original Message - >>> From: "Hein du Plessis" <[EMAIL PROTECTED]> >>> To: >>> Sent: Thursday, August 14, 2008 4:59 PM >>> Subject: [twsocket] Using TWSocket >>> >>> Hi All I'm trying to write a simple TCP/IP app but I'm not sure how to actually send data. The Send Method of ICS v6 requires a data type TWSocketData, yet the documentation states it needs a pointer. On the ICS page there is mention of a sample app, Client5, that would probably solve my problem, but I'm unable to find it in the download package of ICS V6. This is for Delphi. Any help appreciated! Thanks, Hein -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be >>> >>> -- >>> To unsubscribe or change your settings for TWSocket mailing list >>> please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket >>> Visit our website at http://www.overbyte.be >>> >>> >>> -- >>> To unsubscribe or change your settings for TWSocket mailing list >>> please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket >>> Visit our website at http://www.overbyte.be >> >> -- >> To unsubscribe or change your settings for TWSocket mailing list >> please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket >> Visit our website at http://www.overbyte.be >> >> >> -- >> To unsubscribe or change your settings for TWSocket mailing list >> please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket >> Visit our website at http://www.overbyte.be > > -- > To unsubscribe or change your settings for TWSocke