Hi.

Could somebody provide me with a formula (or, better, a
code example) for converting kilobytes to hours (or, time) from the
server?

Thanks.

Re: kilobytes to hours? by Chris

Chris
Tue Jul 22 08:12:36 CDT 2008

On Jul 22, 7:59 am, pbd22 <dush...@gmail.com> wrote:
> Could somebody provide me with a formula (or, better, a
> code example) for converting kilobytes to hours (or, time) from the
> server?

Could you be more specific about what you are trying to do? Kilobytes
is not a measure of time so it makes no sense to convert them to
hours.

Chris

Re: kilobytes to hours? by Martin

Martin
Tue Jul 22 10:05:10 CDT 2008

Hello Chris,

I think the OP wants to find out how long it takes to download a file
from a server.

Well, as such predictions are just based on the current download speed,
the formula would be something like this:

TimeInSeconds=FileSizeInBytes/(BytesPerSecond)

Best regards,

Martin


> On Jul 22, 7:59 am, pbd22<dush...@gmail.com> wrote:
>> Could somebody provide me with a formula (or, better, a
>> code example) for converting kilobytes to hours (or, time) from the
>> server?
>
> Could you be more specific about what you are trying to do? Kilobytes
> is not a measure of time so it makes no sense to convert them to
> hours.

Re: kilobytes to hours? by Herfried

Herfried
Tue Jul 22 11:50:27 CDT 2008

"pbd22" <dushkin@gmail.com> schrieb:
> Could somebody provide me with a formula (or, better, a
> code example) for converting kilobytes to hours (or, time) from the
> server?

There is no way to do that because time cannot be measured in bytes and an
amount of data cannot be measured in hours.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://dotnet.mvps.org/dotnet/faqs/>


Re: kilobytes to hours? by Patrice

Patrice
Tue Jul 22 12:06:52 CDT 2008

Looks like my previous response doesn't show up...

You just have to divide the size of the file by the bandwidth to get the
estimated time for the download (make sure to use consistent units as size
is generally expressed in megabytes and bandwidth in mega*bits*, 1 byte=8
bit).

For example if you try :
http://www.microsoft.com/downloads/details.aspx?FamilyID=0856eacb-4362-4b0d-8edd-aab15c5e04f5&displaylang=en

The size of the file is 22.4 MB. If you select T1 in the bandwidth list
you'll get :

22.4/(1.5/8) = around 119 seconds that is about 2 minutes....

At least this is my understanding about what you would like to do (???)...

--
Patrice


"pbd22" <dushkin@gmail.com> a écrit dans le message de groupe de discussion
: 2e58cc5c-6cb7-4c2f-8b9b-5ae680ccb817@k37g2000hsf.googlegroups.com...
> Hi.
>
> Could somebody provide me with a formula (or, better, a
> code example) for converting kilobytes to hours (or, time) from the
> server?
>
> Thanks.