• 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
NSKeyedArchiver selector not recognized
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSKeyedArchiver selector not recognized


  • Subject: NSKeyedArchiver selector not recognized
  • From: Scott Frankel <email@hidden>
  • Date: Fri, 5 May 2006 09:14:06 -0700


I'm trying to implement archiving. My app goes through the motions of presenting a Save browser, &c., but no file is written to disk.


The debugger shows that the object I'm trying to archive (an NSMutableArray object) contains member object data.

XCode's Run Log posts the message:

	[NSKeyedArchiver archiveDataWithRootObject:]: selector not recognized

The following snippet was built using examples in Hillegas' & Davidson's books:

- (NSData *)dataRepresentationOfType:(NSString *)aType
{
    [fooController commitEditing];
    return [NSKeyedArchiver archiveDataWithRootObject:foo];
}

foo is the NSMutableArray object. The objects foo contains are derived from a class in which I've implemented -encodeWithCoder: for each of its data objects.

I note, however, that the compiler returns a warning:

	'NSKeyedArchiver' may not respond to '+archiveDataWithRootObject:'

Is this indeed the source of the problem? How would I convince the archiver to respond? What might the issue be with the NSData method's selector (listed above)?

Thanks in advance!
Scott
_______________________________________________
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: NSKeyedArchiver selector not recognized
      • From: Mike Blaguszewski <email@hidden>
    • Re: NSKeyedArchiver selector not recognized
      • From: mmalcolm crawford <email@hidden>
  • Prev by Date: View like the ones in Onlife and iCal
  • Next by Date: Re: Animated split view collapsing
  • Previous by thread: View like the ones in Onlife and iCal
  • Next by thread: Re: NSKeyedArchiver selector not recognized
  • Index(es):
    • Date
    • Thread