• 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
Trouble reading a binary file.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Trouble reading a binary file.


  • Subject: Trouble reading a binary file.
  • From: April Gendill <email@hidden>
  • Date: Mon, 13 Dec 2004 08:51:09 -0700

Below is the code I'm trying to use to read a binary file. I'm getting an empty string though.. Can any one shed some light on this?



FILE * fptr;
fptr = fopen([[panel filename]cString],"rb");
char chr;
NSMutableString * fd =[[NSMutableString alloc]init];


while(chr =getc(fptr) != EOF){
[fd appendString:[NSString stringWithFormat:@"%c",chr]];
}
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Trouble reading a binary file.
      • From: Henry McGilton <email@hidden>
    • Re: Trouble reading a binary file.
      • From: Marcel Weiher <email@hidden>
    • Re: Trouble reading a binary file.
      • From: glenn andreas <email@hidden>
  • Prev by Date: Re: Kill other process's warning dialog
  • Next by Date: Text vertical spacing - Yet even more text woes
  • Previous by thread: [SOLVED] character palette trashes attributes
  • Next by thread: Re: Trouble reading a binary file.
  • Index(es):
    • Date
    • Thread