Re: Can't archive NSData :-(
Re: Can't archive NSData :-(
- Subject: Re: Can't archive NSData :-(
- From: Brendan Younger <email@hidden>
- Date: Fri, 15 Jun 2001 00:10:28 -0500
It seems the problem is not with NSData as that conforms to NSCoding.
The problem is with the internal type HTMLDocument. Since you're using
-initWithHTML:, you cannot use the NSCoding protocol as -initWithHTML is
part of the AppKit's NSAttributedString Additions and the additions do
not conform to NSCoding.
My suggestion:
Either use keep your HTML as an NSData object and then convert it to a
NSAttributedString when necessary or use NSAttributedString's -string:
method to get an NSString which is archivable and use initWithString: to
get a NSAttributedString after archiving.
Hope I helped.
Brendan Younger