>From what I see in my shell tests, it appears that Finder reports the "ls
>-leO" size divided by 1000 (for K) divided by 1000 again for M divided by 1000
>again for G and then rounds up to 2 decimal places. for example,
$ ls -leO /Volumes/VD\ 1/OSX-10.8.iso
-rw-r--r-- 1 tjones staff - 4379291648 Feb 19 20:10 /Volumes/VD
1/OSX-10.8.iso
If you then do:
4379291648 / 1000.0 / 1000.0 / 1000.0
You get 4.379 G. Finder reports this as 4.38G
Tim
On Apr 21, 2013, at 7:27 AM, Scott Crick <[email protected]> wrote:
>
> On Apr 21, 2013, at 12:49 AM, Christian Schmitz
> <[email protected]> wrote:
>
>>
>> On 21.04.2013, at 03:21, Scott Crick <[email protected]> wrote:
>>
>>> When I use FolderItem.PhysicalFileTotalLengthMBS, the size of this file is
>>> returned as 331776 bytes. When I divide this by 1024, I get 324 KB. If I
>>> divide it by 1000, I get 331 KB. Neither of these is what the Finder is
>>> reporting—339 KB.
>>
>> FolderItem.PhysicalFileTotalLengthMBS is the size of resource fork and data
>> fork.
>> It does not count extended attributes.
>
> Hmmm... is there another call that works better?
>
>>> Is there a different function I should be using? I need to get the size as
>>> it's reported in the Finder.
>>
_______________________________________________
Mbsplugins_monkeybreadsoftware.info mailing list
[email protected]
https://ml01.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info