EldoS | Feel safer!

Software components for data protection, secure storage and transfer

HttpsClient SendData Event

Also by EldoS: Solid File System
A virtual file system that offers a feature-rich storage for application documents and data with built-in compression and encryption.
Posted: 11/25/2013 01:05:40
by Jeff Newlin (Standard support level)
Joined: 12/26/2010
Posts: 19

I'm debugging a post request and I wanted to view the data that is going out on my Https.Post command. I'm trying to send simple text data.

I just want to write the buffer into a string but I am getting access violation using my current method :

procedure TForm2.HTTPSClientSendData(Sender: TObject; Buffer: Pointer;
Size: Integer);
SString : String ;

SetLength(SString, Size);
Move(Buffer, Pointer(SString), Size);
Memo.Lines.Add(SString) ;
end ;

What might I be doing wrong here?

Thank you,
Posted: 11/25/2013 01:18:55
by Ken Ivanov (EldoS Corp.)

Hello Jeff,

Please use the following syntax for the Move() call:

Move(Buffer^, SString[1], Size);

Note that SString should be an ANSI string, so on Unicode-capable Delphi it should be declared as SString : AnsiString.



Topic viewed 604 times

Number of guests: 1, registered members: 0, in total hidden: 0


Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!