• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
File Size and long longs...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

File Size and long longs...


  • Subject: File Size and long longs...
  • From: email@hidden
  • Date: Wed, 12 May 2004 16:05:27 -0700

ok heres the code which opens a file seeks to then end to retrieve the
file size:

NSFileHandle *fh = [NSFileHandle fileHandleForReadingAtPath:file];
NSNumber *totalFileSize = [NSNumber numberWithUnsignedLongLong:[fh
seekToEndOfFile]];
[fh closeFile];
NSLog(@"%@ - %d",file,totalFileSize);

this is what is output in the log

2004-05-12 16:01:43.524 Rebuild Utility[1154] ABPerson.index - 3313088

the file's size in the finder is - 392 KB - 401,408 bytes

whats up? any help?
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: File Size and long longs...
      • From: Allan Odgaard <email@hidden>
    • Re: File Size and long longs...
      • From: Zach Wily <email@hidden>
    • Re: File Size and long longs...
      • From: Clark Cox <email@hidden>
  • Prev by Date: Re: Unsigned Long Long
  • Next by Date: Re: Behavior of NSTextView scrollRangeToVisible
  • Previous by thread: Re: ConvertMovieToFile w/ iTunes Store m4p's
  • Next by thread: Re: File Size and long longs...
  • Index(es):
    • Date
    • Thread