Newsgroups : Borland : borland.public.delphi.internet.winsock : 2006 Mar : Looking for client/server demo of a proprietary protocol based on TIdCmdTCPServe

www.cryer.info
Managed Newsgroup Archive

Looking for client/server demo of a proprietary protocol based on TIdCmdTCPServe

Subject:Looking for client/server demo of a proprietary protocol based on TIdCmdTCPServe
Posted by:"Maxim Shiryaev" (max..@olma-press.ru)
Date:Fri, 24 Mar 2006 16:51:34

Hi.

I need a demo for the following:

I need to pass TStrings between client server (in both directions).

I've created a TIdCmdTCPServer server which reacts to my commands and
replies with some data.
Let's I have a commad "GETDATA". It replies like:

200 OK
Result1=some string
Result2=another string
.

I can communicate with the server using telnet.

Now I need to create a client. I want to pass some data (also encoded in
TStrings) to my server and get the results back.

For example I want pass something like:

GETDATA
Param1=value1
Paarm2=value 2
.

and get back what the server replies.

I've found WriteHeader and WriteRFCStrings but no ReadHeader or a like. Any
docs available on how to implement all this?

LastCmdResult provides only the reply string without Results string up to
the "." mark line. Should I do it manually - line by line?

How to pass additional params (on additional lines) to the server using
SendCmd?

Thanks.

Maxim.

Replies:

www.cryer.info
Managed Newsgroup Archive