Re: [twsocket] NO_ADV_MT symbol

2005-09-02 Thread Francois Piette
  IMO it is better design to have all access to a given
  component from only one thread. And in that case, you can
  define NO_ADV_MT to have better performances because you
  avoid using a critical section.

 Thank you, this answers my questions.

 I use 2 servers and some clients in same exe, but seperate threads. Atually
 all is controlled from main, but only by posting messages, so no threads or
 components in them is touched from outside the thread. And no
 sockets/components is switched from one thread to another.

 I will then define the NO_ADV_MT and I will get improved performance?

You should. Improvement will be significant if you have a slow processor and a 
fast network. It will
be neglectible if you have a fast processor and slow network.

--
Contribute to the SSL Effort. Visit
http://www.overbyte.be/eng/ssl.html
--
[EMAIL PROTECTED]
Author of ICS (Internet Component Suite, freeware)
Author of MidWare (Multi-tier framework, freeware)
http://www.overbyte.be


-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] FHtmlCharSet property of THtmlSmtpCli

2005-09-02 Thread Bjørnar Nielsen
 I have seen but had not time yet to examine the problem.

Thanks.

You will understand the problem in a minute or so when examining. There is a
FHtmlCharSet wich is used for the html-part, but there is no way of setting
the value unless you derive the component. I just made a set-er an get-er
for it.

Regards Bjørnar


-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] Download time

2005-09-02 Thread G. M. Faggiano

Thank you for your reply.

I am unfamiliar with GetTickCount.  Is that an API or something?  It
doesn't seem to be associated with THttpCli.  Can you give me a small
example of how to use GetTickCount.

Thank you.


 I'm using a ThttpCli to download a 500kb file from my server.  I could
 go bigger, but I have a 6000mb transfer limit per month on my server.
I
 would rather do this another way, but this is the only way I know of.
 Still, doing it this way, I can't figure out how to determine the time
 it took to download the file.  I hope this makes sense to someone.

Use GetTickCount just before starting your download and GetTickCount
from the OnRequestDone event.
You'll have an exact measure of the time in milli-seconds (be aware
GetTickCount wrap back to 0
after approximatively 49 days of up time). Given the size of the
download you've done, you can
compute the thruput with very simple math.

You can also start a download of a large file and stop it after, let's
say 15 seconds using Abort.
Looking at the received size during 15 seconds, you can compute the mean
thruput during those 15
seconds.

--
[EMAIL PROTECTED]
http://www.overbyte.be

- Original Message - 
From: G. M. Faggiano [EMAIL PROTECTED]
To: twsocket@elists.org
Sent: Thursday, September 01, 2005 3:58 AM
Subject: [twsocket] Download time


 Hello,

 I'm trying to write a little app that downloads a file from my server
at
 regular intervals and tells me what my true connection speed is.
 I'm doing this because I use a broadband connection through my lan.
So,
 I have no real way to check my current speed without going to one of
 those online speed tests.  I just want to represent my speed in mps
via
 an icon in my system tray.  If anyone has a better Idea on how to get
 the result I'm after, please tell me.  Here is what I'm doing now.

 I'm using a ThttpCli to download a 500kb file from my server.  I could
 go bigger, but I have a 6000mb transfer limit per month on my server.
I
 would rather do this another way, but this is the only way I know of.
 Still, doing it this way, I can't figure out how to determine the time
 it took to download the file.  I hope this makes sense to someone.

 Also, Francois, your components are awesome!  I've been using them for
 about two years now.  I'll be sure to send you a post card.
 -- 
 To unsubscribe or change your settings for TWSocket mailing list
 please goto http://www.elists.org/mailman/listinfo/twsocket
 Visit our website at http://www.overbyte.be

-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be



-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] Download time

2005-09-02 Thread Arno Garrels
Angus Robertson - Magenta Systems Ltd wrote:
 I am unfamiliar with GetTickCount.  Is that an API or something?
 
 it also wraps after 49 days, so
 some care is needed for applications that run longer without a reboot.

For calculating ticks elapsed I use this function:

function CalcTicksAppart(const T1: DWORD): DWORD;
var
T2 : DWORD;
begin
T2 := GetTickCount;
if T2 = T1 then
Result := T2 - T1
else
Result := MAXDWORD - T1 + T2;
end;
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be