[twsocket] Test message, please do not respond

2018-08-31 Thread François Piette
Test message, please do not respond

 

--

François Piette

 

-- 
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 with a few thousand clients

2018-08-26 Thread François Piette
> why when i give each client its own DataAvaialbe i hav eno problems at all
> what is the diffrence ? and should i do that with all other events ?

Your question is not clear.
Please reformulate it and keep a SHORT summary of the previous message, just 
enough to understand what you ask.

To have a good answer, you have to ask a good question...

--
francois.pie...@overbyte.be
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] Freeze on TWSocketServer close

2018-08-18 Thread François Piette
>> My program (a service) hosts 4 TWSocketServers in main thread.
>> Sometimes, when I ask the service to stop, the program freeze 
>> after I call TWSocketServer Close function

>You are assuming all sockets disconnect instantly and are the freeing
>the component, when activity may still be happening.  

>You should wait until there are zero clients on the server before
>freeing it.  Stop listening first, so new clients can not connect while
>you wait, at least one minute or more. 

This depict the most graceful, orderly shutdown and that is good.

Another possibility is to stop listening on the server socket (close) and
call Abort on each client socket and then call Abort on the server socket.
This should not block anything and quit quickly. Of course any connected
client will probably receive/experience an error because of abort.


--
francois.pie...@overbyte.be
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 with a few thousand clients

2018-08-12 Thread François Piette


I forget to say that to support a few thousand simultaneous client, it is
likely that yu should pour TWSocketServer code into a thread to service,
let's say, 500 client per thread. And you should probably NOT use the main
thread to run TWSocketServer code.

Be aware that ICS is asynchronous and it will multitask (cooperatively)
nicely within a thread and serve a lot of connections in a single thread.
But this is not infinite : Windows has his limits (Nothing in ICS limit the
number of connections nor the number of threads).

If you are used with some other socket component, you should probably forget
everything you know. ICS has a totally and unique programming model. What is
good for a synchronous blocking socket is NOT what you should do with ICS
which is asynchronous, non-blocking and event driven.

--
francois.pie...@overbyte.be
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 with a few thousand clients

2018-08-11 Thread François Piette
> i have created a tcp server using Twsocket but after 40 clients connected
> the server stopped from listing

There is nothing in ICS which limits the numbers of simultaneous client.
Only machine and operating system resources are limiting.

To handle a few thousands simultaneous connections, it is likely that you
need a Windows SERVER operating system, not a Windows workstation.

The most limiting factor in the number of socket you may open is the memory.
Each socket needs memory in non-paged memory and the amount of non-paged
memory is directly linked to the total amount of memory the system has.

Of course, your application may be limited by other limits on systems
resources. Beware of what you do for each connection. For example, you may
quickly exhaust the number of available handles if you don't program
correctly.

As Angus said, you sould test for errors everywhere and get error code using
GetLastError to know which limit you exhausted?

--
francois.pie...@overbyte.be
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] Idle Socket is closed even with KeepAlive under windows

2018-07-11 Thread François Piette
> I working on a device communication protocol using TCP with 
> TWSocketServer and TWSocket. (Delphi XE Project)

Strange protocol. Do you have a formal description of the actual protocol?

--
francois.pie...@overbyte.be
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


[twsocket] ICS registration

2018-06-21 Thread François Piette
Hi !

 

As you subscribed to ICS support mailing list, you probably use ICS. Good !

But have you taken time to register your ICS copy ?

 

ICS is freeware but to use it, you must register it.

 

Registration is very simple: just mail a [real, paper] picture postcard to
the author (me). You can find instructions in readme.txt file.

 

Thanks.

 

PS: If you already sent your picture postcard, simply ignore this message.

If you wants to know if I received it, then you must tell me when you sent
it, from which country and what the picture is (I have several thousand
postcards !).

 

--

francois.pie...@overbyte.be

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] New version for Android and Linux

2018-06-14 Thread François Piette
> I read on some website that the next version of ICS will be compatible
with Android. Already have some forecast of the next version? 

That is true that I started the port. But I lack time to do it on my spare
time.
I'm waiting for a sponsor company... I the past, I developed the SSL version
financially supported by a lot to ICS users who got it quickly. Later it
became part of the free distribution. I had hoped that the same could be
done for Android and Linux.

Anyone ?

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] OverbyteIcsFtpCli unrecognised

2018-06-08 Thread François Piette
> [dcc32 Fatal Error] main.pas(15): F2613 Unit 'OverbyteIcsFtpCli' not found.

You have 3 choices:
1) Add the path where you have installed ICS to the global search path in the 
IDE
2) Add the path where you have installed ICS to the global search path for the 
project
3) Add to the project the unit OverbyteIcsFtpCli.pas and all the others unit 
the compiler will complain (There will be a lot!).


--
francois.pie...@overbyte.be
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


[twsocket] Test 3

2018-03-19 Thread François Piette
Please don’t reply to this Test message.

 

--

François Piette

 

-- 
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


[twsocket] Test 2

2018-03-19 Thread François Piette
Please do not respond to this test message.

 

--

François Piette

 

-- 
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] Wiki and Website down

2018-03-18 Thread François Piette
Hi !

Up and running again.

--
francois.pie...@overbyte.be
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


[twsocket] Mailing list test

2018-03-18 Thread François Piette
The list was down. Just cheking if it works now.

 

--

francois.pie...@overbyte.be

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


[twsocket] Wiki and Website down

2018-03-18 Thread François Piette
Hi everyone,

 

I’m sorry to tell you that currently  
www.overbyte.be et wiki.overbyte.be are down.

One of the server disk failed and for unknown reason the RAID system is
incredibly slow, making the server unusable.

I’m working on it. Be patient.

 

--

francois.pie...@overbyte.be

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] Getting an exception EHttpException in module myapp.exe at 00000000. Request aborted on timeout.

2017-12-01 Thread François Piette
> Getting an exception EHttpException in module myapp.exe at .
Request aborted on timeout.

You should instrument your program with madExcept or similar product so that
you get a stack trace and other informations when the exception occurs.
You'll then probably quickly find the cause.

madExcept is free for non-commercial use and not expensive at all for
commercial use. I use it with great success for years. See http://madshi.net

--
francois.pie...@overbyte.be
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] Twsocket Problem over Internet.

2017-11-17 Thread François Piette
Not correct.

Please narow your question. Make it more specific. Describe your "problem".
Try to apply the advice we gave to you in previous answers.
Have you read the two article link I gave to you a few days ago ?
We will not write the code for you.

Regards,

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be


-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de
Fatimire
Envoyé : lundi 13 novembre 2017 21:31
À : ICS support mailing
Objet : Re: [twsocket] Twsocket Problem over Internet.

anything is wrong ?
thank you everybody.

Receiving...
var
Count : Integer;
InString: string;
begin
with Sender as TClient do
try
if IsRcvBin then
begin
if not assigned(MS) then
  MS := TMemoryStream.Create;
Count := Receive(@Buffer[1], BLOCK_SIZE);

if Count <= 0 then //check if we received something
Exit;
// write the buffer to our memorystream
MS.Write(Buffer, Count);
if MS.Size = ExpectedStreamSize then
//have we received whole stream
Image2.Picture.Graphic.LoadFromStream(MS);
Exit;
end;

InString := ReceiveStr;
if (InString.StartsWith('IMAGE:')) then
InString := InString.Substring(6);

ExpectedStreamSize := StrToInt(InString);
IsRcvBin := True;// we start receiving binary
data
LineMode := False;   // so we put linemode off
 except  end;
end;



-- 
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] Twsocket Problem over Internet.

2017-11-11 Thread François Piette
> Your receiving is also likely to fail, LineMode should not be used when
you expect binary data, 

Agreed.

> and makes a program more complex than necessary swapping back and forward
while receiving, checking line end is not very hard. 

Disagreed.
What would be easier for Fatimire is to send the image length a single
integer (4 bytes is probably enough) instead of a text line. It is easier
because the length is fixed. When receiving, it is enough to check if the
first 4 bytes are received and the get the length without further parsing.

The code should be written using pure event driven, without wait loops.

Fatimire should read the following documentation:
 http://wiki.overbyte.eu/wiki/index.php/Asynchronous_Paradigm
 http://wiki.overbyte.eu/wiki/index.php/Sending_and_receiving_data


--
francois.pie...@overbyte.be
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] Twsocket Problem over Internet.

2017-11-11 Thread François Piette
Hi !

Sending is OK although not optimal because of buffering.  At least, be sure
to no close the socket before the sending is done: TWSocket will buffer data
for you (up to the amount of available ram space). It is bette as Angus
said, to send by blocks.

For receiving, you must first receive the line you send before the image, to
get the image size. And then you must receive block by block until you get
the whole image.

You may switch TWSoket from line mode (for the line you sent with the image
size) and the go back to binary mode to receive the rest block by block as
you do.

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be




-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de
Fatimire
Envoyé : vendredi 10 novembre 2017 20:32
À : ICS support mailing
Objet : [twsocket] Twsocket Problem over Internet.

HI for all, i do a prototype to transfer a imagem overt internet with
Twsocket, but in local network works fine, but when i test with a remote
computer in internet connection the file is sended but dont receive or
receive a image with lost collor.

sending ...
try
  FMS.Seek(0, soBeginning);
  Form10.wscktsrvr1.Client[0].SendStr('IMAGE:' + IntToStr(FMS.Size) +
sLineBreak);
  Form10.wscktsrvr1.Client[0].Send(FMS.Memory, FMS.Size);
finally
Receiving ...
if (FIsBiniary) then begin
iCount := Socket3.Receive(FRcvd + FWritePtr, FFileSize - FWritePtr);
Inc(FWritePtr, iCount);

if (iCount = 0) then begin
  FIsBiniary := False;
end;
if FWritePtr = FFileSize then begin
  F := TMemoryStream.Create();
  try
F.Write(FRcvd[0], FFileSize);
Memo1.Lines.Add('write');
  finally
oBMP := TBitmap.Create;
f.Seek(0, soBeginning);
oBMP.LoadFromStream(F);
Image1.Picture.Assign(oBMP);
FreeMem(FRcvd, FFileSize);
FreeAndNil(oBMP);
F.Free;
  end;

  FIsBiniary := False;
  Socket3.LineMode := True;
end;
Exit;
  end;

  sRcvBuf := Socket3.ReceiveStr.Trim;
  Memo1.Lines.Add(sRcvBuf);

  if (sRcvBuf.StartsWith('IMAGE001:')) then begin
sRcvBuf := sRcvBuf.Substring(9);
Memo1.Lines.Add('Size: '  + sRcvBuf);

FFileSize := StrToIntDef(sRcvBuf, 0);
FWritePtr := 0;
GetMem(FRcvd, FFileSize);
Socket3.LineMode := False;
FIsBiniary := True;
  end;
end;

someone can help-me ?

Sent from [ProtonMail](https://protonmail.ch), encrypted email based in
Switzerland.
--
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] Wiki...

2017-10-26 Thread François Piette
Problem is fixed, at least as seen from here. 
There was a file system error. No idea where it came from. If was no a disk
space issue: there are still a few GB available on disk.
Let me know if everything is OK and specially if your last changes/uploads
are valid.

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be



-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Angus
Robertson - Magenta Systems Ltd
Envoyé : jeudi 26 octobre 2017 15:25
À : twsocket@lists.elists.org
Objet : Re: [twsocket] Wiki...

> Is it just me or has the Wiki
> (http://wiki.overbyte.eu/wiki/index.php) disappeared?

It was fine on Tuesday, but the VM has probably run out of disk space
(again) so is currently dead, only Francois can fix it. 

As always, the latest overnight zip and SSL files may be downloaded from my
web site where SVN is hosted: 

https://www.magsys.co.uk/delphi/magics.asp

The zip is currently the same as the latest stable version V8.50, I copied
it on Monday and there are no changes since then.  Only difference is I
removed the massive SVN change log to save space. 

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

-- 
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] TSslHttpCli on runtime

2017-06-15 Thread François Piette
>  in my project I have a TStringGrid with some lines, 
> I need to create a TSslHttpCli component for each grid line, 
> and make independent simultaneous connections, I create a Thread for each
line 

This is definitely not required with ICS. A single thread, even the main
thread can handle a lot of connections simultaneously without blocking. See
sample program OverbyteIcsHttpAsy.dpr provided with ICS.

> but I am having problem with The cookies, how to use the cookies of the
component TSslHttpCli that is in the main form, 
> he who has logged in to authenticate in the site

I remember that cookie handling where discussed a few days ago.

--
francois.pie...@overbyte.be
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


[twsocket] wiki.overbyte.be should be working

2017-06-02 Thread François Piette
The issue with http://wiki.overbyte.be should be fixed.

There is a redirection to the .eu wiki.

Let me know as soon as you discover an issue with one of ICS websites.

 

Regards,

--

francois.pie...@overbyte.be

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] OpenSSL 1.1.0f and 1.0.2l support

2017-05-26 Thread François Piette

> www. is working for me, but wiki. does not

Thanks Eugene.
I checked the DNS and I can confirm that the record for wiki.overbyte.be is
gone! I will fix this ASAP.

-- 
francois.pie...@overbyte.be
http://www.overbyte.be




-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de
Eugene Kotlyarov
Envoyé : vendredi 26 mai 2017 19:26
À : ICS support mailing
Objet : Re: [twsocket] OpenSSL 1.1.0f and 1.0.2l support

www. is working for me, but wiki. does not

-Original Message-
From: TWSocket [mailto:twsocket-boun...@lists.elists.org] On Behalf Of
François Piette
Sent: May 26, 2017 10:24
To: 'ICS support mailing' <twsocket@lists.elists.org>
Subject: Re: [twsocket] OpenSSL 1.1.0f and 1.0.2l support

Is DNS resolution working ? I mean does wiki.overbyte.be answers ? (It is
redirected to the .eu) Anybody else having issue with
http://wiki.overbyte.be or http://www.overbyte.be ?

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare The author of the
freeware Internet Component Suite (ICS) http://www.overbyte.be





-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Angus
Robertson - Magenta Systems Ltd Envoyé : vendredi 26 mai 2017 19:17 À :
twsocket@lists.elists.org Objet : Re: [twsocket] OpenSSL 1.1.0f and 1.0.2l
support

> BE suffix works as well ! And it is even the preferred address.

Not from here: Firefox can't find the server at wiki.overbyte.be.

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

--
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] OpenSSL 1.1.0f and 1.0.2l support

2017-05-26 Thread François Piette
Is DNS resolution working ? I mean does wiki.overbyte.be answers ? (It is
redirected to the .eu)
Anybody else having issue with http://wiki.overbyte.be or
http://www.overbyte.be ?

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be





-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Angus
Robertson - Magenta Systems Ltd
Envoyé : vendredi 26 mai 2017 19:17
À : twsocket@lists.elists.org
Objet : Re: [twsocket] OpenSSL 1.1.0f and 1.0.2l support

> BE suffix works as well ! And it is even the preferred address.

Not from here: Firefox can't find the server at wiki.overbyte.be.

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

-- 
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] OpenSSL 1.1.0f and 1.0.2l support

2017-05-26 Thread François Piette
> http://wiki.overbyte.eu/wiki/index.php/ICS_Download
> PLEASE NOTE the EU in the URL, not BE, this is a new wiki server.  

BE suffix works as well ! And it is even the preferred address.

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be




-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Angus
Robertson - Magenta Systems Ltd
Envoyé : vendredi 26 mai 2017 18:11
À : twsocket@lists.elists.org
Objet : [twsocket] OpenSSL 1.1.0f and 1.0.2l support

Four new zips for Win32 and Win64 versions of OpenSSL 1.1.0f and 1.0.2l can
now be downloadable from the Wiki at:

http://wiki.overbyte.eu/wiki/index.php/ICS_Download

PLEASE NOTE the EU in the URL, not BE, this is a new wiki server.  

There are no security fixes, just bug fixes related to building the
libraries.

OpenSSL has clarified that OpenSSL 1.1.1 will add support for TLS/1.3 and
will only be released once the protocol is finalised, it's currently at
draft 20. It will need a new version of ICS for support, but this is
anticipated to be only minor changes.  

There is a recent blog that describes OpenSSL changes for TLS/1.3, which
seems to concentrate on simplifying SSL, removing lots of old ciphers,
hashes and protocols, and speeding up negotiation. 
 
https://www.openssl.org/blog/blog/2017/05/04/tlsv1.3/

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

-- 
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


[twsocket] DNS issue solved

2017-04-18 Thread François Piette
Hi !

 

The DNS issue that started last Friday is now fixed.

 

You can access wiki.overbyte.be and svn.overbyte.be as it should.

Those of you having added a line in their hosts file for svn.overbyte.be
should now comment this line out (Add a # sign in front of the line for
later reuse).

 

Let me know whenever you experience difficulties.

 

Have a nice day.

--

François Piette

 

-- 
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


[twsocket] RAD Studio Survey

2017-04-13 Thread François Piette
Embarcadero currently conduce a survey about their products (Mainly Delphi
and C++ Builder).

There are several places where you can plug ICS in the “other” reply.

Don’t forget to do it when it applies!

Anyway, it is interesting for you and all the community to tell Embarcadero
what you think.

Survey link : https://www.surveymonkey.com/r/2017RADStudioSurvey

 

--

francois.pie...@overbyte.be

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] overbyte.be down?

2017-04-04 Thread François Piette
> I'm I right that www.overbyte.be is down ?

I was since a few days. 
Now the problem is solved and you should be able to access 
http://www.overbyte.be and http://wiki.overbyte.be again.

By the way, my email address was also down. It is up and running again but I 
probably lost the messages sent in the past few days.

--
francois.pie...@overbyte.be
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] TWsocket transfer TmemoryStream

2016-12-06 Thread François Piette
> Always is needed use the OnDataSent event ?
> I need only transfer the tmemorystream off a Timage1 to Timage2 over
twsocket.

You may send a huge block of data in one Send call. An entire image if you
like. BUT remember TWSocket is asynchronous and transmitting data over the
network takes time. You call to the Send method will return almost
instantly, way long before the data is actually sent: TWSocket will
automatically buffer the data in memory and send it in the background for
you. This may take a lot of memory if you send large data. This may be of no
importance for your application, or it IS important...

When using OnDataSent event, you have control on the size of data that is
memorized. For example you can read your stream 4KB (Any value is OK) at a
time, send that chunk of data and then read the next chunk from the
OnDataSent event, that is the next chunk will be read and put in internal
TWSocket buffer only when previous chunk is sent. This is how the HTTP
component (both client and server) are working to send data. This way it
doesn't matters if a multi GB file is sent. The memory used is always the
size of the chunk your application read.


--
francois.pie...@overbyte.be
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] TWSocket Client Timeout.

2016-12-03 Thread François Piette
Hello Alexandre,

There is nothing preventing data from a TTimer event.
Are you using "sync" functions or "async" functions ? Are you using wait
loops ?

When you send data from TTimer event, is this "transparent" to the protocol
you are using ? Maybe the data send from TTimer interfere with data sent (or
received) from other parts of your program?


--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be




-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Moro
Alexandre
Envoyé : vendredi 2 décembre 2016 13:44
À : 'ICS support mailing'
Objet : Re: [twsocket] TWSocket Client Timeout.

Hello !

I finaly found where comes from the problem :
When the clients connects to my server, i send to everyone a lot of data
from a TTimer.

If i remove the SendStr() call, everything works fine !!!

So please,
1) Can you explain me what is wrong in calling SendStr from a TTimer ?
2) How can this call, block every differents object based on TWSocket,
server object and client object ?
3) Why there are no error event nor exception throw...

Solution :
1)
I tried to set mpWSocketServer->MultiThread = true; But it doesn't change
anything...

2)
Do i have to implement a Thread for all the SendStr be apart from the main
thread ?
I create a Thread, pass the TWSocketServer object as parameters, and a FIFO
list with event.
When i complete this list, the thread process the new data and SendStr...


I'm shocked that this call can interfere seperate object...

Thank you !

Best regards,
Moro Alexandre.


-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Moro
Alexandre
Envoyé : vendredi 2 décembre 2016 08:14
À : 'ICS support mailing'
Objet : Re: [twsocket] TWSocket Client Timeout.

I trying to investigate more and more and i see that i cannot open new
sockets on the server, it refuse the connection, below is the packets
captured in wireshark :
Document joint : spuriousretransmission.pcapng

The application i openned who crashed all the twsocket open two new socket
on this server !
And in netstat the server socket are still in listenning state, (it happen
on localhost and from a remote computer).

Moreover the last 4 connection are in FIN_WAIT_2

Maybe it is a start...

Moro Alexandre.

-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Angus
Robertson - Magenta Systems Ltd Envoyé : jeudi 1 décembre 2016 16:54 À :
twsocket@lists.elists.org Objet : Re: [twsocket] TWSocket Client Timeout.

> In this time, did you already ear something like that with ICS ?
> Have you any idea where data can be blocked, and in this state what 
> can i do more than inspecting by wireshark and netstat ???

If I understand you correctly, you want to keep remote TCP/IP sockets
connected for several days at a time, presumably over a LAN or maybe a WAN? 

There are so many ways a connection can be lost, routers and switches,
hardware issues, software interference, Windows Updates, etc.  

Even with keep alive, TCP/IP sockets can say connected but not be, the only
reliable way is to send and echo data, a proper handshake. 

The probability of it being a bug in ICS that no-one else has noticed is
highly unlikely, but not impossible, as explained previously I did fix a
timeout issue that caused a socket to be closed earlier this year, which I
found in one of my applications. 

You really need to find a way of bullet proofing your application, so it
reconnects if nothing is received for x second/minutes/hours, or use regular
handshaking for a more reliable and shorter timeout. 



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


--
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] OpenSSL 1.1.0c support

2016-11-11 Thread François Piette
I think we should thank Angus for managing the whole process of code
signing.
This is a real plus toward a better ICS.

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be



-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Angus
Robertson - Magenta Systems Ltd
Envoyé : vendredi 11 novembre 2016 17:03
À : twsocket@lists.elists.org
Objet : [twsocket] OpenSSL 1.1.0c support

OpenSSL has issued a new version 1.1.0c fixing several security issues.


Two new DLLs for Win32 and Win64 versions of OpenSSL 1.1.0c may be loaded
from the Wiki at:

http://wiki.overbyte.be/wiki/index.php/ICS_Download

SVN and the overnight zip will be updated tonight.

The OpenSSL DLLs and EXE files included in the OpenSSL 1.1.0c and 1.0.2j
zips are now digitally code signed 'Open Source Developer, François PIETTE',
the lead developer for ICS.  

Digital code signing allows Windows to automatically check the authenticity
and origin of binaries and whether they have been corrupted or patched.  In
File Explorer, right click on a file, Properties, Digital Signatures should
show two signatures with SHA1 and
SHA256 algorithms, and allow the digital certificate to be viewed and it's
status checked. 

The Magenta Systems Code Signing Trust and Certificate Check component at
https://www.magsys.co.uk/delphi/magtrustchk.asp may be used in applications
to check the correctly signed DLLs are being used by ICS, with this
functionality planned to be included in ICS itself.  The component can also
self check a signed application for corruption and tampering.  

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

-- 
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] More friendly winsock exceptions

2016-10-24 Thread François Piette
> We also have a long term problem with the OnError event. It skips raising
an exception and 
> simply calls the event without the actual error information being
available, and in a few 
> places continues program flow, not sure how useful this is, it probably
confuses users.

The OnError event can stay just like it is now and a new event OnException
can be created with the instance of the TWSocketException so that every
information is available.


--
francois.pie...@overbyte.be
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] More friendly winsock exceptions

2016-10-22 Thread François Piette
> It's annoyed me for many years that many internet applications give
unfriendly errors, 
> sometimes just five digit error codes, sometimes terse messages.  
> Specifically, when starting a server on an address and port that is being
used, 
> the current ICS exception is:
> Address already in use (#10048 in Bind)
> I propose to change this to:
> Another server is already listening on 192.168.1.120:80

This is not a bad idea but the implementation must be made so that no
existing code is broken. It is likely that existing code rely on those
specific error string.

IMO the correct way to handle this enhancement is to extend ESocketException
to add more fields with more details about the exception, without changing
the current error message.

Currently we simply have:
  ESocketException   = class(Exception);

It could become:
  ESocketException   = class(Exception)
  private
FIP   : String;
FPort : String;
FProto: String;
FErrorCode: Integer;
FErrorMessage : string;
  public
constructor Create(AErrorCode   : Integer; 
   const AErrorMessage  : String; 
   const AMessage   : String;
   const AIP: String;
   const APort  : String;
   const AProto : String);
property 
property IP   : String  read FIP;
property Port : String  read FPort;
property Proto: String  read FProto;
property ErrorCode: Integer read FErrorCode;
property ErrorMessage : String  read FErrorMessage;
  end;

  
constructor EHTTPProtocolException.Create(
AErrorCode   : Integer; 
const AErrorMessage  : String; 
const AMessage   : String;
const AIP: String;
const APort  : String;
const AProto : String);
begin
  FErrorCode:= AErrorCode;
  FErrorMessage := AErrorMessage;
  FIP   := AIP;
  FPort := APort;
  FProto:= AProto;
  inherited Create(AMessage);
end;

The argument ErrorMessage shall be the current exception message so that
current user code is not broken.
Of course you may add more fields to better describe the exception and you
may create a whole hierarchy, for example by high level protocol.


--
francois.pie...@overbyte.be
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] Recent SSL improvements and OpenSSL 1.1.0

2016-09-02 Thread François Piette
> This message attempts to summarise SSL changes in ICS in the last six
months, up to V8.33.  

I would like to thanks Angus for his huge work on ICS-SSL.
This is a wonderful work. 

Congratulations Angus,
--
francois.pie...@overbyte.be
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] The hosting site for the list will go to maintenance Friday 26/08/2016 evening to Saturday until done

2016-08-26 Thread François Piette
>   Why not use a Forum instead of mailing lists ?

This has been discussed a lot of times along all the years.
In short: No, I don't like forum for many reasons.
Btw: This wouldn't change anything related to maintenance.

--
francois.pie...@overbyte.be
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] Can TSmtpCli be used to connect to an MS Exchange Server?

2016-07-22 Thread François Piette
> The office recently changed to using a Microsoft Exchange server and 
> I need to continue sending out emails from our Delphi application
> Can this be done?

You must enable  Exchange POP3 connector:
https://technet.microsoft.com/en-us/library/bb124934(v=exchg.150).aspx

> If so, what do I used for the host address?

The IP address of the computer where Exchange is running.
No need to change your current Delphi/ICS software.

--
francois.pie...@overbyte.be
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] Request for access to the mailing list

2016-07-22 Thread François Piette
> I've requested to be added to the TWSocket mailing but have not had any
response.

Obviously you are connected since the message I answer to is from the
mailing list...

> Approximately how many active users are on the mailing list?

Something like 700.

> Can I post my questions on this list?

Sure!

> Thank you

You're welcome.

--
francois.pie...@overbyte.be
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] Version Delphi Berlin

2016-07-22 Thread François Piette
> Hello, have any plans to release a version for the latest version of
dellphi, Berlin? the component will continue?

It is already available. See
http://wiki.overbyte.be/wiki/index.php/ICS_Download

--
francois.pie...@overbyte.be
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] From Indy to ICS and ICS implementation

2016-07-22 Thread François Piette
> I'm currently using Indy to communicate with TCP/IP devices. We have about
> 3 devices and growing. We're getting to the point where the number 
> of concurrent connections are too many too handle for a single Indy server

> instance. I have to start looking at load balancing but before I do that I
want to 
> have a look a asynchronous sockets.

> In extreme cases we have about 3000 concurrent connections but
>  Indy can't cope with that so we limit it to 1000 and queue the remainder.

Using ICS with a large number of connections, you use a list of threads.
Each thread can handle hundreds or thousands of connections (TWSocket). The
number of connections per thread depends mainly on the traffic load, not the
number of connections. If each connection sit idle for most of the time,
then a single thread can handle 1000 or 2000 of them. 

ICS doesn't impose any limit in the number of connections. The limits are
only at the Windows operating system which imposes a limit on the number of
simultaneous open handles (A socket is seen as a handle). The limit depends
on the Windows edition. A server edition has a much higher limit.

Another OS limit is the size of non paged memory pool. Each socket takes
some byte there. To support a high number of concurrent sockets, you must
have a lot of memory (Non paged memory size depends on the total memory
available).

Use TWSocketThrdServer component to automatically handle thread creation.
You specify how many client per thread you want and the component does it
for you.

Please note that if the work requested by a client implies a blocking
process, such as a long SQL query, then you MUST use a separate worker
thread to execute that lengthy process, or use Windows Asynchronous I/O. if
you don't do that, while a thread is blocked handling your processing, then
no other connection handled by that blocked thread will do anything. You
really must think asynchronous programming everywhere.

Regards,

--
francois.pie...@overbyte.be
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] Check Remote Port

2016-07-22 Thread François Piette
 >   Is there any easier way to check if a port is open on a remote server
at runtime ?

The only reliable way to check for open port is to try to connect to it. If
you get error 10061, then the port is not opened at server side.

Btw: In you code, it is better to not use a wait loop. Instead use the event
OnSessionConnected and check the error there.


--
francois.pie...@overbyte.be
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] SSL post extremely slow

2016-04-26 Thread François Piette
Hello,

You are updating your progress bar and memo in the event, each time it is
called. This probably slow down everything.
Please retest without any GUI interaction during transfer.

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be



-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de brian
-
Envoyé : mardi 26 avril 2016 03:58
À : ICS support mailing
Objet : Re: [twsocket] SSL post extremely slow

Did the test with a 4,5MB file, non-SSL

Firefox: 2.6s

Saved Uploaded File OK
New File Name: d:\tempwork\telecom\uploads\20160426-021729_Aion 2016.Apr.21
- 10.57.48.png
File Size: 4,553,987
Upload Duration: 2.6 secs
Speed: 1,754,908 chars/sec
Upload FileName: Aion 2016.Apr.21 - 10.57.48.png
FileTitle: aion ss test
Post URL: http://www1.telecom-tariffs.co.uk/testing/uploadfile.htm

ICS: 34.1s

POST /testing/uploadfile.htm HTTP/1.0
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */*
Referer: http://www1.telecom-tariffs.co.uk/testing/uploadfile.htm
Content-Type: multipart/form-data;
boundary=147712359214935
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101
Firefox/45.0
Host: www1.telecom-tariffs.co.uk
Content-Length: 4554186

34133ms

unit Unit1;
>
> interface
>
> uses
>   Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, 
> System.Classes, Vcl.Graphics,
>   Vcl.Controls, Vcl.Forms, Vcl.Dialogs, OverbyteIcsWndControl,
>   OverbyteIcsHttpProt, Vcl.StdCtrls, Vcl.ComCtrls,
>
>   MultipartBuilder;
>
> type
>   TForm1 = class(TForm)
> Button1: TButton;
> Button2: TButton;
> HttpCli1: THttpCli;
> ProgressBar1: TProgressBar;
> Memo1: TMemo;
> procedure Button1Click(Sender: TObject);
> procedure HttpCli1SendData(Sender: TObject; Buffer: Pointer; Len:
> Integer);
> procedure HttpCli1BeforeHeaderSend(Sender: TObject; const Method:
> string; Headers: TStrings);
> procedure HttpCli1SendEnd(Sender: TObject);
>   private
> { Private declarations }
>   public
> { Public declarations }
>   end;
>
> var
>   Form1: TForm1;
>   x: Int64;
>
> implementation
>
> {$R *.dfm}
>
> procedure TForm1.Button1Click(Sender: TObject); Var fil: AnsiString;
> mp: TMultiPartObject;
> fl: string;
> tm: TMemoryStream;
> Const cT = '147712359214935';
> begin
>   // Fill multipart data+file
>   fl := 'z:\Aion 2016.Apr.21 - 10.57.48.png';
>   mp := TMultiPartObject.Create(cT);
>   tm := TMemoryStream.Create;
>   tm.LoadFromFile(fl);
>   ProgressBar1.Max := tm.Size;
>   With mp do begin
> AddFileFromStream('image',ExtractFileName(fl),'image/png',tm);
> CloseData;
> fil := GetFile;
>   end;
>   mp.Free;
>
>   x := GetTickCount;
>   With HttpCli1 do begin
> url := 'http://www1.telecom-tariffs.co.uk/testing/uploadfile.htm';
> SendStream := TMemoryStream.Create;
> SendStream.Write(fil[1],length(fil));
> SendStream.Seek(0,0);
> RcvdStream := TMemoryStream.Create;
> Timeout := 5;
> Agent := 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) 
> Gecko/20100101 Firefox/45.0';
> ContentTypePost := 'multipart/form-data; boundary='+cT;
> Reference := 
> 'http://www1.telecom-tariffs.co.uk/testing/uploadfile.htm
> ';
> try
>   PostAsync;
> except
>   On E:Exception do ShowMessage(E.Message);
> end;
>   end;
> end;
>
> procedure TForm1.HttpCli1BeforeHeaderSend(Sender: TObject; const Method:
> string; Headers: TStrings);
> begin
>   Memo1.Lines.Add(Headers.Text);
> end;
>
> procedure TForm1.HttpCli1SendData(Sender: TObject; Buffer: Pointer; Len:
> Integer);
> begin
>   ProgressBar1.Position := ProgressBar1.Position + Len; end;
>
> procedure TForm1.HttpCli1SendEnd(Sender: TObject); begin
>   With HttpCli1 do begin
> SendStream.Free;
> RcvdStream.Free;
>   end;
>   Memo1.Lines.Add('');
>   Memo1.Lines.Add(IntToStr(GetTickCount-x)+'ms');
> end;
>
> end.
>


On Mon, Apr 25, 2016 at 7:12 PM, Angus Robertson - Magenta Systems Ltd <
an...@magsys.co.uk> wrote:

> > Are there any known issues with SslHttpCli for sending data? I've 
> > observed the following:
> > Sending a 3MB picture to imgur:
> > * with ICS/OpenSSL: takes ~27 seconds
>
> Done some testing with a view to investigating this issue, but not 
> currently sure it's worth any more time.
>
> I'm using an updated version of the sample OverbyteIcsHttpPost against 
> the ICS web server (no SSL).
>
> With both running on my PC:
> File Size: 20,450,630
> Upload Duration: 204 msecs
> Speed: 100,248,186 chars/sec
> Upload FileName: speed20meg.zip
>
> With the ICS web server running on my public server, over FTTC with a 
> 10Mbit/sec upload speed, from ICS:
> File Size: 20,450,630
> Upload Duration: 17.56 secs
> Speed: 1,164,349 chars/sec
> Upload FileName: speed20meg.zip
>
> Using Firefox to the same public server:
> File Size: 20,450,630
> 

Re: [twsocket] Android version of ICS?

2016-03-28 Thread François Piette
> Is there even a future for Delphi?  

Well, this is not the lace to discuss this topic but I'm convinced there is
a future as a cross platform.

--
francois.pie...@overbyte.be
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


[twsocket] ICS reaches 20 years !

2016-03-28 Thread François Piette
Hi !

 

I’m proud to say that ICS reaches 20 years next month.

 

--

francois.pie...@overbyte.be

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] Android version of ICS?

2016-03-28 Thread François Piette
> Years ago, (could be decades now) I sent my postcard to France and tried
to use ICS.

Actually you sent your postcard to Belgium :-)

> none of my clients care or expressly do not want their application running
on a tablet or phone.

I started to port TWSocket to Android, thinking that some of my client would
want some stuff ported to a tablet or a smartphone. None asked that. ICS has
always been a "side effect" of my own business. I never had and won't
probably never have no money to develop ICS as a product. This means I will
delay ICS for Android until I get a business large enough to fund ICS for
Android without impairing the business budget too much...

Today I hope that IoT will open the business in which ICS would find a
better place. IoT is full of communication so ICS should have his place.


--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be


-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de John
Dammeyer
Envoyé : lundi 28 mars 2016 07:05
À : 'ICS support mailing'
Objet : Re: [twsocket] Android version of ICS?

I must admit I'm a little confused and not just about ICS.  Years ago,
(could be decades now) I sent my postcard to France and tried to use ICS.
Yet over the years my Delphi projects tend to be menu's and buttons that
interface through USB Serial or CAN bus with 8 bit characters or bytes.
Even now when I need to update an old project I have to go through the
headache of changing chars and strings.

I've stopped at XE7.  A valiant effort in hopes to be able to perhaps write
a program that was transferable to ipads or iphones or androids.  Alas, I'm
still just writing windows programs and none of my clients care or expressly
do not want their application running on a tablet or phone.

I do have an application that sends out DMX512A light show UDP packets using
IdUDPClient.  I don't even remember why I used that library.  Why would I
use ICS instead?

Yet, the IoT is interesting.  A simple application that interacts with my
new Raspberry Pi or Beagle Bone Black with Wifi dongle is appealing.   One
that is portable so my iPhone or Windows Laptop can send a message to the
Beagle to control a couple of outputs  to turn on lights or send CAN message
to my network of surplus Olympic Rings lights.

So where would I start?  Why would I use the twsocket family now?

Thanks
John Dammeyer





> -Original Message-
> From: TWSocket [mailto:twsocket-boun...@lists.elists.org] On Behalf Of 
> Angus Robertson - Magenta Systems Ltd
> Sent: March-27-16 10:51 AM
> To: twsocket@lists.elists.org
> Subject: Re: [twsocket] Android version of ICS?
> 
> 
> > I know you guys are probably very busy, but I need to ask.
> > Is there any progress in an android version of ICS?
> > I'm fully into Firemonkey making an Android App but the Indy 
> > component is very difficult to work with (for me anyway) Would it be 
> > possible to give an update on the status (if any?)
> 
> Sorry, there is no Android progress.
> 
> No-one has volunteered the hundreds of hours it would take, no-one has 
> offered to pay for the development needed.  We did ask Embarcadero but 
> they seem content with Indy (which I assume they make a financial 
> contribution towards).
> 
> The only positive news is the latest Delphi roadmap mentions the next 
> release 10.1 Big Ben will include 8-bit UTF8 strings in mobile, where 
> currently ICS would need it's own 8-bit implementation (which was 
> started).  This will simplify sharing code between platforms.
> 
> 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

--
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] Pinging multipe hosts

2016-03-13 Thread François Piette
> I will be writing both server and client softwares. No need for a web
server.

Then it is easy for you to add an application level ping. That is each
server will response to a simple command ("Hello") with a simple answer
("OK").
One or more clients can periodically send that "Hello " command and verify
it receives the correct "OK" answer with a reasonable time.

This is called an "end-to-end" application check.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] Pinging multipe hosts

2016-03-12 Thread François Piette
> I have a Windows service application. That needs to check if several hosts
(IP numbers, 
> no need to DNS resolve) are still alive. Assuming easiest way to ping
them. Since that will
> require no installation on my clients at all. Please suggest other ways
that you think apply.

Ping messages (ICMP) are frequently blocked for servers.
If you have control over the hosts, you can be sure to enable it.

But ping doesn't mean the services are running, it only means that the
server OS is running.
The best way to check for an alive host is to try a connection to the host,
connection to the application that you must verify.


--
francois.pie...@overbyte.be
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] How do i Send Recive Client list using Twsocketserver and Twsocket?

2016-03-08 Thread François Piette
Hello,

> i converted the indy client and server To TWsocket and Twsocket server and
here is the code of server after convert

Instead of publishing a lot of some competing socket component that no one
will read, please ask specific question about ICS and TWSocket;
Don't forget to look in the numerous sample programs delivered with ICS.

One main difference between ICS an Indy is the asynchronous  operation of
ICS. There is NO direct conversion. Thinsk about synchronous (Indy) as
MS-DOS like programming and asynchronous operation (ICS° like Windows
programming. This article
[http://wiki.overbyte.be/wiki/index.php/Asynchronous_Paradigm] frequently
help people.

If you ask specific question about ICS, we will be able to help you.

--
francois.pie...@overbyte.be
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] How do i Send Recive Client list using Twsocketserver and Twsocket?

2016-03-08 Thread François Piette
> ics dont have any sample on how to send receive memory stream i no this is
nothing to do with indy i thought i can use ics in same way

TWSocket has a Send method which you can use to send any data providing a
pointer and a count. This is perfect for sending a TMemoryStream:
WSocket1.Send(MyMemorStream.Memory, MymemoryStream.Size);
That's it !

--
francois.pie...@overbyte.be
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] THttpCli and XML...

2016-03-07 Thread François Piette
> I switched to a TWSocket and sent the complete post URL, parameters and
XML data in one send 
> and the server responded without error. So, the header data the THttpCli
component was adding
> to the XML document was not allowed by the server. Only the XML data.

This makes me thinking your server doesn't use HTTP protocol. Instead it
uses a simple TCP session (Something like telnet).
If the server support HTTP, it will for sure return an error if you don't
send a HTTP request! You said the server is OK with the XML data sent thru a
TCP session and I conclude that is doesn't support HTTP.


--
francois.pie...@overbyte.be
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] Wiki...

2016-03-03 Thread François Piette
Hello,

Sorry, I have not seen your email. Please resent it by forwarding this one
to me directly.

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be




-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de zayin
Envoyé : jeudi 3 mars 2016 04:06
À : twsoc...@elists.org
Objet : [twsocket] Wiki...

Hello,

Last week I decided to help with the wiki and make a couple of entries. I
joined the wiki, sent the required email for editing permission and I have
not heard back.

Ideas?

Thanks,

Mark


--
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] Lazarus/FPC/Linux...

2016-01-23 Thread François Piette
> Would making V8 work be a huge undertaking? 
> I see that V8 supports POSIX. So maybe it would work with
Lazarus/FPC/Linux?

I have no idea about the work required to make ICS work with
Lazarus/FPC/Linux. I only guess it is not trivial since whatever they say,
FPC is far from being compatible with Delphi.

Of course you are welcome to do that work and share it with the community.

Regards,
--
francois.pie...@overbyte.be
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] TWSocket Digest, Vol 634, Issue 1

2015-12-29 Thread François Piette
> Registered, but it won't let me edit TnScript page, seems I need to be in
the 'writer' group to do edits.

You have to email me privately the usercode you selected, then I can give
you write access.

--
francois.pie...@overbyte.be
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] Please delete my ticket

2015-11-02 Thread François Piette
Hello,

Each list recipient received your message as an email. Some list recipient
are making an online archive which I doesn't control. You must ask those
sites to remove your message from their archive.

Sorry.
--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be



-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de
Hartmut von Hoff
Envoyé : vendredi 30 octobre 2015 11:07
À : twsocket@lists.elists.org
Objet : [twsocket] Please delete my ticket

Hello,

can you delete my request mail I sent on 08. September 2015 to your list,
please? Because it contains phone number and email address of my office.
This can be found via search engines and causes much spam! I didn't know
that these messages are not private. In my opinion they could be readable
only for list subscribers.

Thank you in advance!

Kind regards
Hartmut von Hoff
Software developer

ATON GmbH
für Planung, Automatisierung und Umwelttechnik Lindenstr. 2
38154 Königslutter
Telefon: +49 (0) 53 53 /  91 75-0
Telefax: +49 (0) 53 53 / 91 75-25

hartmut.vonh...@atongmbh.de


Registernummer: Wolfsburg HRB 100600
Ust ID: DE 115 863 507
Registergericht: Braunschweig
Geschäftsführer: Dipl.-Ing. Ralf Uetze
Diese E-Mail könnte vertrauliche und/oder rechtlich geschützte Informationen
enthalten. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail
irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und
vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte
Weitergabe dieser Mail sind nicht gestattet.
This e-mail may contain confidential and/or privileged information. If you
are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail. Any
unauthorised copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.

--
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] Old versions of OpenSSL

2015-03-08 Thread François Piette
 I'd assume most users what to keep up to date with the latest encryption 
 standards and ciphers and try to use the latest OpenSSL versions.

Agreed.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Angus
Robertson - Magenta Systems Ltd
Envoyé : dimanche 8 mars 2015 15:11
À : twsocket@lists.elists.org
Objet : [twsocket] Old versions of OpenSSL

Can anyone think of a good reason for ICS to continue support for old
versions of OpenSSL, prior to 1.0.1 when support for TLS 1.1 and 1.2 was
introduced? 

OpenSSL 1.0.1 (three years ago) added some new API calls relating to these
new versions of TLS, and keeping support for older versions would add a
little complexity. 

I'd assume most users what to keep up to date with the latest encryption
standards and ciphers and try to use the latest OpenSSL versions. 

OpenSSL does maintain support for the 0.9.8 and 1.0.0 with security fixes,
not sure why.

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

-- 
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] Sending font styles and colors over network

2014-12-06 Thread François Piette
 am building a chat system and I want to send basic text chat with font
size/font color/font styles 
 for each user am doing this via strings and sending to server and back to
client but I noticed 
 after a while and when more then a few users are typing the text chat
becomes unstable 
 and incorrect font styles / colors and sizes happen and only way to fix it
is to re-login so am
 wondering what would be best way to send the information over network so
it would be 
 stable and reliable.

Are you using TCP or UDP ?

UDP is by construction an unreliable protocol which is good for video or
sound streaming where it is not very important to have some errors.
TCP is by design a reliable protocol. It means you are sur to receive
everything that has been sent, in the correct order without any error. If
one of the conditions cannot be met, the you get noticed (First it starts to
be slow because of transmit retries).

TCP is reliable, but of course your code MUST check for all errors! It is
easy to program without checking any error, but then you lose the
reliability, not because of the internet protocol, but because of your code.

Also, a common error with event driven asynchronous component such as ICS,
is to call ProcessMessages (or any other derived method) without knowing
exactly what it does. Incorrect use of ProcessMessages and the likes may
result in lost events and then lost data.

Another common error when using TCP is to forget that TCP is a stream
oriented protocol. This means that although you receive everything sent, in
the correct order and without error, several sent may be received as a
single, larger chunk. Or a large data chunk sent at once may be read split
into smaller chunks. This means you must at the application level handle
this split/concatenation. It is exactly like writing to a file. The file
reader cannot know how the file has been written. A text file can only be
read line by line because of the CRLF which is used as line delimiter.

My recommendation is to use TCP protocol and program everything
asynchronously, using events.

You may have a look at the chat client/server demo application in ICS.

Btw: sending image, sound, text, color and font doesn't matters as far as
transport is concerned. TCP nor UDP cares about what you transport. It is at
the application level that it matters. It is your responsibility to design
your application protocol so that the receiver knows what the sender has
sent.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-- 
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


[twsocket] TR: OverbyteIcsFtpCli.pas error ?

2014-12-01 Thread François Piette


-Message d'origine-
De : Nicolas MARCHAND [mailto:nicolas.march...@club-internet.fr] 
Envoyé : lundi 1 décembre 2014 16:53
À : francois.pie...@overbyte.be; arno.garr...@gmx.de
Objet : OverbyteIcsFtpCli.pas error ?

Hello François and Arno,

I really thank you for your components !

J'ai détecté une anomalie dans l'unité OverbyteIcsFtpCli.pas

I think procedure :

procedure TSslFtpClient.PBSZAsync;
begin
 FFctPrv := ftpFctProt;
 ExecAsync(ftpProtAsync, 'PBSZ ' + IntToStr(FPBSZSize), [200], nil); end;

should be :

procedure TSslFtpClient.PBSZAsync;
begin
 FFctPrv := ftpFctPbsz;
 ExecAsync(ftpPbszAsync, 'PBSZ ' + IntToStr(FPBSZSize), [200], nil); end;

Sincerely,
Nicolas

-- 
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] ICS updated for Delphi XE6

2014-04-18 Thread François Piette
 Did you have to change anything in your ICS to make it work for Delphi
XE6?

Nothing serious.


-- 
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


[twsocket] ICS updated for Delphi XE6

2014-04-17 Thread François Piette
Hi everyone !

 

ICS-V8 has been updated for Delphi XE6.

No new feature, simple update for Delphi XE6 (VCL and FMX).

Download as usual.

 

--

François Piette

 

-- 
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] sendfile

2014-03-18 Thread François Piette
 can i request please for an updated sendfile example found in overbyte.be
site?
 i simply need it transfer file in our network

This sample is maybe not the best one.
Depends on what type of transfer you actually need. Please tell us your
requirements.
The easiest is to use the FTP or HTTP components. One server component at
one end and one client component at the other end.
To start with, you can play with the FTP demos included in ICS distribution
(OverbyteIcsFtpServ and OverbyteIcsFtpTst). Those are the easiest and yet
complete.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] TWsocketServer and ENQ ascii char

2014-03-12 Thread François Piette
 En fait j'ai trouvé le problème , j'avais mis LineMode à false pour le
TWSocketServer , 
 mais il fallait le mettre à false pour le TWsocketClient également.

Yes, indeed. TWSocketServer doesn't transfer any data. It is delegated to a
TWSocket (Actually a TWSocketClient which Is a TWSocket having a little bit
more features).

 Merci Beaucoup .

You're welcome.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] TWsocketServer and ENQ ascii char

2014-03-11 Thread François Piette
 I use the tcp-ip to connect medical devices via the standard protocol ASTM
.

ASTM is the name of a standardization organization which probably - among
other things - publish the protocol you are using.
Is any reference document describing the protocol available?


 In ASTM to establish communication with the instrument, we must respond to
Ascii character ENQ received by an ACK. 
 However, it seems from what you have told me that TWsocketserver does not
consume the ENQ. 
 Is there a way to solve this problem? 

Are you writing a client program or a server program?
A client program will connect (that is initiate the connect) while a server
program will passively wait for connection.

For a client, you should a a TWSocket component.
For a server, you should use a TWSocketServer, but each connected client is
handled by a TWSocket component.

Whatever TWSocket you have, you should turn off line mode (this is off by
default anyway). This way, you get an OnDatavailable as soon as the remote
part is sending the ENQ. You then call Receive to get hand on the received
characters and you can use Send to send the ACK.

This is much the same as when using RS232 (I know you use it). The only
serious difference is that data is sent by packet. That means you may
receive a lot of characters at a time, usually a complete message.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-- 
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] Multiple TCp clients

2014-02-26 Thread François Piette
 Make sense but if you have a few TWSocets running at the same time and
from every 
 connection writing to a shared TMemo you do not need to synchronize it
somehow ?

If you application is single threaded, no you don't need any
synchronization, it is built-in by Windows message queue system.
If your application is multithreaded, remember you can NOT access a TMemo
from code executed in the context of a thread. You must use a mechanism to
make TMemo updated in the context of the main thread. Synchronize is one
[poor but easy] method of doing data.

 OK, maybe my problem was different.

I think so.

 Thanks for elaborating this.

See my other messages.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] Multiple TCp clients

2014-02-25 Thread François Piette
 It seems that you are facing a common issue with Windows application, sharing 
 resources.
 In your case the shared resource is the memo.

He didn't say his program is multithreaded. And he don't need multithreading 
with TWSocket and there is definitely no such issue.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-- 
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] Multiple TCp clients

2014-02-25 Thread François Piette
 By 'bogged down' I mean that I can send and receive, alternating instruments 
 but eventually 
 the instruments (or the software) stop working correctly

You have to better described stop working correctly if you want to 
significant help. What happens (or doesn't)? Is there any error code or 
exception? Put breakpoint, add display messages and all kind of debugging stuff.

 Do you have a postcard from Orillia, Ontario, Canada yet?

Honestly, I can't tell you: I have received more than 4000 postcards for ICS 
registration. Send yours :-)

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com






-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de 
Christopher Lusty
Envoyé : mardi 25 février 2014 19:27
À : ICS support mailing
Objet : Re: [twsocket] Multiple TCp clients

Thank you Francois,

I was considering trying the array but wasn't sure that it would improve my 
results - having a single event handler is an excellent idea.

By 'bogged down' I mean that I can send and receive, alternating instruments 
but eventually the instruments (or the software) stop working correctly - my 
guess is that using only one OndataReceive event will so a long way to 
resolving this

Do you have a postcard from Orillia, Ontario, Canada yet?

Regards

Lusty

-Original Message-
From: François Piette
Sent: Tuesday, February 25, 2014 1:07 PM
To: 'ICS support mailing'
Subject: Re: [twsocket] Multiple TCp clients

Hello Chris,

Don't use TWSocketServer.

You should create an array (or a list or any collection you like) or TWSocket 
components. Then connect each TWSocket to his own instrument. You may use the 
same event handlers for all the TWSocket, simply use the Sender argument in 
each event to now who is who. All the sockets will work in parallel without any 
problem, without using thread and without requiring any synchronization with 
GUI components.

 If I leave both instruments connected the system runs for a bit but 
 eventually gets bogged down.

Not sure by what you mean by bogged down. Ru your app under the debugger and 
report any exception. Also use madExcept to catch many errors with memory 
allocation and things like using freed objects and so on.

--
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de 
Christopher Lusty
Envoyé : lundi 24 février 2014 22:38
À : twsocket@lists.elists.org
Objet : [twsocket] Multiple TCp clients

Hello all,

I am trying to interface with some laboratory instruments, previously we 
used RS-232, now we are working on the next generation of machines

The instruments act as servers, I have established reliable communications 
with each of the instruments as individual units using WSocket as a client. 
Now, I would like to set it up such that I can talk to each instrument in 
turn (it is never necessary to talk to more than one machine at a time).

As an experiment I have built a small app with two TWServers on board, each 
is connected to buttons to dis/connect, send the contents of an edit box and 
place the results in a memo. Each client represents a different instrument.

The setup works reasonably well if I connect-send-disconnect each instrument 
in turn. If I leave both instruments connected the system runs for a bit but 
eventually gets bogged down. I have no problem with having to make and break 
when I switch machines except for the fact that sometimes the reconnect can 
take a few seconds which, of course, slows things.

Any suggestions for this TCP newbie as to how to use multiple clients within 
one piece of software would be greatly appreciated. I’d  like to avoid 
threading.

BTW – compiler is Delphi 7 (soon to be ported to XE2)

Best regards

Chris Lusty
(first time poster)

C.W. Lusty, PEng MBA
Hinterland Software Ltd.
Software manufacturers for the PC-Titrate family of products www.titrate.com
--
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] Handshake of TWSocket

2014-02-18 Thread François Piette
 is there anybody who can and will explain to me if the socket handshake
protocol is 
 implemented and how the handshake works ? I have problems connecting to 
 socket applications using handshake.

A socket by itself is not a protocol nor it implement any handshake. A
socket is just an abstraction layer to access network services. It is the
link to low level protocol engine such as TCP/IP and the applications which
then can implement higher level protocols such as HTTP (for web) and SMTP or
POP3 for email.

You should better describe your problem and you'll get a better answer.


-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-- 
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] TWSocket strange problem

2014-01-28 Thread François Piette
Everything works just fine except that once in a few restarts to my
application I get an exception
that IP address is not defined. My IP is defined and has no problems that I
can see ?

Try assigning IP, Port and Proto each time before calling connect.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-- 
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] TWSocket strange problem

2014-01-28 Thread François Piette
 I may have a problem in my code but this is a bit strange ?

Have you tested with one of the supplied samples ?

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-- 
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] [Off Topic] Vote for Delphi on Code2013

2014-01-03 Thread François Piette
 Well, I said how to vote: You can cast your vote by sending a tweet

 So it's effectively a survey of Twitter followers about their favourite
language, 
 excluding the many people who don't use Twitter g 

Indeed. As a mitigating factor, most people by today have a twitter account.

 If they wanted a properly representative survey, there would be several
voting methods. 

Is the relative number of language users different among those having a
tweeter account and the others? I don't think so. So the result IS
representative.

--
francois.pie...@overbyte.be
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


[twsocket] [Off Topic] Vote for Delphi on Code2013

2014-01-02 Thread François Piette
[Off Topic] 

 

You can vote for your favorite language (I hope it is Delphi but you can
vote for anything).

The website http://code2013.herokuapp.com/ has a nice statistic about
language used in 2013.

You can cast your vote by sending a tweet with hashtag #code2013 followed
the name of your favorite language.

 

--

francois.pie...@overbyte.be

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] [Off Topic] Vote for Delphi on Code2013

2014-01-02 Thread François Piette
 You can vote for your favorite language (I hope it is Delphi but you can
 vote for anything).

I do not understand this page. How do you vote? Just by a click on the
image?
Just from the name I'd prefer pogoscript, whatsoever that is ;)

Well, I said how to vote: You can cast your vote by sending a tweet with
hashtag #code2013 followed the name of your favorite language.

Of course you need a tweeter account to vote. A tweet is much like an SMS:
it is maximum 140 characters. You send it to either someone specific (you
mention his account name after the '@' sign in front of your message), or to
nobody in particular in which case your tweet is only seen for those doing a
search for it or those having subscribed to your tweets. This is what
Code2013 do: every 10 minutes a robot does a search on tweeter for
#code2013 and add the language names found in the tweet and present the
result in the graphic you saw.

--
francois.pie...@overbyte.be
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] TWSocket Digest, Vol 550, Issue 2

2013-12-24 Thread François Piette
This fix is not OK. FHSocket may be negative. It has to be cast to WParam.
See other messages.
-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de
Michael Gasser
Envoyé : mardi 24 décembre 2013 12:06
À : twsocket@lists.elists.org
Objet : Re: [twsocket] TWSocket Digest, Vol 550, Issue 2



Hi pde...@gmail.com

I still think there is a little bug in OverbyteIcsWSocket.pas (most recent
version 8.06 of OverbyteIcsWSocket.pas [ISC v7 was OK]) wihich causes this
problem in function TCustomWSocket.Send(Data : TWSocketData; Len : Integer)
: Integer; at line PostMessage(Handle, FMsg_WM_ASYNCSELECT, FHSocket,
IcsMakeLong(FD_WRITE, 0));

[described in my posts 7.11. 12.11.2013]

In some cases the values of FHSocket, FState are FHSocket 1 and FState =
wsConneced WHILE ENTERING the function TCustomWSocket.Send - BUT their
values change to -1, wsClosed in TryToSend;  [socket not connected]

If these values change to -1, wsClosed (in TryToSend; ) the error you
describe occurs.


To get rid of the error you mention:

1. Open OverbyteIcsWSocket.pas
2. In  OverbyteIcsWSocket.pas search for TCustomWSocket.Send.

Code as is:
if bAllSent then begin
{ We post a message to fire the FD_WRITE message which in turn will}
...
{ the send function.   }
PostMessage(Handle,
FMsg_WM_ASYNCSELECT,
FHSocket,
IcsMakeLong(FD_WRITE, 0));
end;

Add the line if FHSocket  0 :

if bAllSent then begin
{ We post a message to fire the FD_WRITE message which in turn will}
...
{ the send function.   }
if FHSocket  0 then  // add this line...
PostMessage(Handle,
FMsg_WM_ASYNCSELECT,
FHSocket,
IcsMakeLong(FD_WRITE, 0));
end;


This fixes your problem.

or even better:
Go to the procedure TryToSend; and set the variable bAllSent to false 
whenever an error like #10057 occurrs. This fixes the problem too.


Regards
Michael




 Message: 1
 Date: Sat, 21 Dec 2013 15:06:45 +0200
 From: ? ??? pde...@gmail.com
 To: twsocket@lists.elists.org twsocket@lists.elists.org
 Subject: [twsocket] Errors while send, if client disconnected from
 socket
 Message-ID:
 CA+70vSCkD396D+CbzGpCzxWFhPNX68VktK9byvTwQw6fuF=j...@mail.gmail.com
 Content-Type: text/plain; charset=ISO-8859-1

 Hello

 Sometimes client can disconnect on multithreaded server while send, after
 that I receive
 Range check error or
 Socket is not connected (#10057 in Send)

 How can I avoid these errors?
 I'm checking client state before send.
 Must I ignore both these errors? If yes, I can understand to ignore
 #10057, but why shuld I ignore range check error.
 It is very rarely error (one time on 1.000.000 send), but it happens every
 day on my server.

 //TTCPClient = class(TsslWSocketTHrdClient)

  if (FTcpClient as TTCPClient).state = wsConnected then
try
  (ftcpclient as TTCPClient).Send(data, 4);
 // here error (in debug I see that client disconnected after entering in
 function Send
except
  on e: exception do
log.debug('Error in sendstr TClient.writelnuncompressed:' +
 e.Message);
end;


 Thank you.


 

-- 
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] Errors while send, if client disconnected from socket

2013-12-21 Thread François Piette
 Sometimes client can disconnect on multithreaded server while send, after
that I receive 
 Range check error or Socket is not connected (#10057 in Send)

 How can I avoid these errors?
 I'm checking client state before send.
 Must I ignore both these errors? If yes, I can understand to ignore
#10057, but why shuld I ignore range check error.
 It is very rarely error (one time on 1.000.000 send), but it happens every
day on my server.

You can safely ignore error 10057 but you should not get any Range check
error.
Please add ICS source path to your project so that the source are compiled,
do not use package and then run under debugger. This way, you'll find
exactly where the Range Check Error exception occurs and from then we can
probably help you.

If you can't reproduce the issue using the debugger, then use madExcept
which will produce a stack trace when the exception occurs and we'll also
know where it is exactly.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de ?
???
Envoyé : samedi 21 décembre 2013 14:07
À : twsocket@lists.elists.org
Objet : [twsocket] Errors while send, if client disconnected from socket

Hello

Sometimes client can disconnect on multithreaded server while send, after
that I receive Range check error or Socket is not connected (#10057 in
Send)

How can I avoid these errors?
 I'm checking client state before send.
Must I ignore both these errors? If yes, I can understand to ignore
#10057, but why shuld I ignore range check error.
It is very rarely error (one time on 1.000.000 send), but it happens every
day on my server.

//TTCPClient = class(TsslWSocketTHrdClient)

  if (FTcpClient as TTCPClient).state = wsConnected then
try
  (ftcpclient as TTCPClient).Send(data, 4); // here error (in debug
I see that client disconnected after entering in function Send
except
  on e: exception do
log.debug('Error in sendstr TClient.writelnuncompressed:' +
e.Message);
end;


Thank you.
--
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] ICS, FireMonkey, Android, Windows and PostMessages

2013-12-16 Thread François Piette
 Window handles do not exist in OS X too but that can be emulated as I
showed in ICSv8. 
 The nature of PostMessage() and SendMessage() is that they take a target
(call it handle).

This is what I've done. The Windows handle is the instance of
TMessagingSystem. I made PostMessage a method of the object because I like
the OOP way, but PostMessage could have been done a simple function taking
the TMessageSystem instance as first argument like a Window Handle. This
is just the same.

 Will your port introduce a new incompatible source branch as it was the
case with your Kylix port in the past? 

I don't know yet. I'm progressing slowly and carefully, building other
applications in the meanwhile. This way I get more experience with the new
Android API and will in the end produce better code. Obviously my goal is to
hide as much as possible changes.

 I already wrote an AnsiString class which does the required work.
 I saw it, that's far away from solving the problem! 

At least it solve all problem I had until now. And since it is a plain
class, IMO it is easy to solve other problems, if any.
 
 Let's see and count the memory leaks and other issues caused by ARC-ed
objects 
 over the next years in your ported ICS source code.

We'll see. Anyway we have no other choice. ARC is mandatory on Android.

 Well, zero-based strings is a complety unnecessary mess IMO.

Agreed.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] ICS, FireMonkey, Android, Windows and PostMessages

2013-12-16 Thread François Piette
Thanks for your favorable opinion.
You're welcome.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com





-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de
Walter Bohlin
Envoyé : lundi 16 décembre 2013 00:38
À : ICS support mailing
Objet : Re: [twsocket] ICS, FireMonkey, Android, Windows and PostMessages

Francois,

You are nothing short of genius. I cannot tell you how much your ICS
components for C++ Builder have helped me complete work that I wasn't able
to do on my own. On top of that, it was an education for me, one that is far
from over, even at my advanced age.

Thank you ever so much!

Walter


On 12/15/2013 11:29 AM, François Piette wrote:
 While busy at porting ICS to Android, I had the need of replacing 
 Windows custom messages by something else which is portable across 
 Windows and Android.

   

 Something else? Not sure! Finally, I build a really small piece of 
 code which implements Windows messages on Android and on Windows.


 Of course the Windows implementation makes use of Windows own 
 messaging as usual. On Android it makes use of the looper API.



 The result is code which allows to build application 100% portable 
 between Windows and Android and yet make use of Windows custom messages.


 As you know ICS code and many samples make heavy use of Windows custom 
 messages. Problem solved!



 Read full article at:
 http://francois-piette.blogspot.be/2013/12/firemonkey-android-windows-
 and.ht
 ml
 http://www.linkedin.com/redirect?url=http%3A%2F%2Ffrancois-piette%2Eb
 logspo 
 t%2Ebe%2F2013%2F12%2Ffiremonkey-android-windows-and%2Ehtmlurlhash=7lc
 q_t=t
 racking_anet

   


--
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] How can I get a buffer of TnScript

2013-11-21 Thread François Piette
How can I get  a buffer of TnScript some else way?

 TTnScript inherit from TEmulVT which has a buffer for what you see on 
 screen. There is a Screen property which in turn has a Lines property.
 This is an array of records made of Txt : AnsiChar (Character displayed) 
 and Att : Byte which is the attribute (color and so on).

 Unfortunately TEmulVT is unsuitable. 

Unless I misunderstood your problem, a TTnScript is a TTnEmulVT which is a
TEmulVT. So you don't have to replace your TTnScript by a TEmulVT because it
is already a TEmulVT (with some added features of course).

 So I want to get the TnScript's buffer and write to file by himself.

Did you had a look at the source code ?


If I misunderstood your problem, please rephrase it. Don't use the same
description again but use other words and sentences.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] ICS :: Need help and example for HTTP Proxy Server

2013-11-10 Thread François Piette
 I have downloaded GpHttpProxy Demo project just now.
 You right - don't want to compile
 And I am little lost :)

Can't help you without error messages.
First of all, prefix all ICS units by OverbyteIcs (For example WSocket
became OverbyteIcsWSocket).
Then only minor changes should be required.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] Example of reverse mx lookup with TDNSQuery

2013-10-21 Thread François Piette
 Does anyone know of an example of how to use TDNSQuery to do a reverse MX
lookup? 

TDNSQuery doesn't do revers MX lookup.
I don't think it is possible anyway.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] Post data lost

2013-10-11 Thread François Piette
 No clue if this a bug, I could simply provide sample code to reproduce the
issue.

Please do.
Put your code somewhere on the web and publish a link to the mailing list
(don't attach your code to a message for the list, it will be rejected).

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] Attach to a target thread?

2013-10-10 Thread François Piette
 So my question: is there any way to attach a client connection to 
 another thread immediately, from the main thread?

 Probably, but I've said I've not done it myself, no need.  
 Others may have done so,

 
This is not always possible, at least without modifying TIcsWndControl. The
problem is windows API cannot (AFAIK) be used to attach an existing windows
(Message queue in fact) to an existing thread. One must recreate the window
in the context of the thread. 

 but I don't believe it necessary for your application.

I share this opinion.
I would let the client sockets attached to a single the thread (no
necessarily the main thread) and handle all communication. Once a job has
been received, then the data is passed to a worker thread, thru a queue, for
processing. Probably a single queue serviced by a pool of thread is enough.


-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] Delphi TServerSocket vs ICS equivalent

2013-10-09 Thread François Piette
 The data is enclosed with a standard tag format. In this case it is
mos./mos, so I know when 
 I have received a complete message 

So you have a delimiter which is /mos. It could be sed for TWSocket
LineMode.
Note that you cannot have embedded messages in messages.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-- 
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] Fetch image across LAN, WAN?

2013-08-08 Thread François Piette
 Do you think this can be done with ICS and Delphi 4?

Delphi 4 or XE4 ?
Of course no problem with XE4.
If you still have an ICS version working with D4, then you can do it.

Downloading an image is not different than downloading any file or any HTML
page. One you get the JPG (or GIG or PNG or whataver) into a file, you can
then load it into your favorite TImage. You may also use ICS to put the file
to a TMemoryStream and load the image component from the stream. This way
there will be no disk activity.

-- 
francois.pie...@overbyte.be
Embarcadero MVP
http://www.overbyte.be
http://francois-piette.blogspot.com




-Message d'origine-
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de TK
Boyd
Envoyé : jeudi 8 août 2013 14:24
À : twsocket@lists.elists.org
Objet : [twsocket] Fetch image across LAN, WAN?

I have an IP Cam which will service a request from Firefox, as below, 

and return to Firefox an image...

http://192.168.0.252:92/SnapshotJPEG?Resolution=320x240Quality=Clarit
y

I want, using Delphi 4, to create a simple little app which would have an
edit box, a Do It button and a TImage object.

Don't let the long, complex URL be an issue... I think that the app I want
could be tested just by putting a little jpg on my web server, and pointing
the app at that. If the app could be smart enough to know whether it was
looking at a .bmp or a .jpg, and deal with either, so much the better. But
to start with, it can just assume that the data is a jpg file.

I would put the http://192... snapshot... line in the edit box, click the
Do It button, and hope to see the image from the camera in the TImage
object.

Do you think this can be done with ICS and Delphi 4?

Any hints?

(I once wrote an app with ICS to read the source of a webpage, i.e. 
the HTML behind what Firefox displays if a URL is visited... The biggest
puzzle I have just now is...

If I sort of do that again... how do I intercept the part of what the web
server returns that is the image? How do I decode what the server sends
into something I can send to the TImage object?

I don't expect anyone out there to be able to do all this for me... 
but maybe someone knows of an existing tutorial on the subject... 
remembering my Delphi 4 constraint, please. Or maybe someone knows it 

Just Can't Be Done?

As I said... hints welcomed, and I hope I can take it from there...

Tom

Delphi and Lazarus Tutorials, incl ICS material...
http://sheepdogguides.com/tut.htm
--
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


[twsocket] Dynamic web page using Delphi, ICS and DWScript

2013-06-09 Thread François Piette
Hello,

 

I updated the OverbyteIcsWebAppServer demo with code to handle dynamic web
page creation using DWScript. See my blog at: 

http://francois-piette.blogspot.be/2013/06/dynamic-web-page-using-delphi-ics
-and.html

 

The code is uploaded to the SVN repository for ICS V8, but it has not been
incorporated to the OverbyteIcsWebAppServer because it requires DWScript to
be installed. See the blog article or the comments in front of the new unit
OverbyteIcsWebAppServerDWScriptUrlHandler.pas for the two changes required.

 

-- 

francois.pie...@overbyte.be

Embarcadero MVP

 http://www.overbyte.be http://www.overbyte.be

 http://francois-piette.blogspot.com http://francois-piette.blogspot.com

 

 

-- 
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