realbasic-nug
[Top] [All Lists]

Re: FolderItem.Length Feature Request

To: REALbasic NUG <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: FolderItem.Length Feature Request
From: Harrie Westphal <harriew at frontiernet dot net>
Date: Thu, 30 Jun 2005 14:37:40 -0500
Delivered-to: realbasic-nug at lists dot realsoftware dot com
References: <47121EA3-985C-4469-94B3-E78A734698C6 at texastowers dot com> <add5d81527a77fb19f165de10bc7c234 at great-white-software dot com>

On Jun 30, 2005, at 10:31 AM, Norman Palardy wrote:

I'd really like a long integer (64 bit) so it's absolutely precise. Comparing doubles or using a double in a loop like the following may not be reliable with very large files.

        dim fileSize as double
        dim i as double

        fileSize = f.length

        for i = 1 to fileSize

                .. do something to every byte ..
        next

Norman,

Are you sure about this? You will be working with whole numbers, no fractional parts, so why would a double be wrong as long as your file size does not exceed 16 digits, about 10,000 terabytes. As long as I have been programming the only problems I have ever seen with floatiing point calculations is when numbers are not whole numbers. But, this is my experience on IBM mainframes, but still, floating point, double/single, is floating point.

Just curious why you say this in case I am missing something.

=== A Mac addict in Tennessee ===

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>