I am trying to convert NSAttributedString
to NSData
using RTFDFromRange
method. Getting this:
No visible @interface for 'NSAttributedString' declares the selector 'RTFDFromRange:documentAttributes:
What is wrong with my code?
NSAttributedString *val=self.textview.attributedText;
NSData *data = [val RTFDFromRange:NSMakeRange(0, self.textview.text.length) documentAttributes:nil];