This code should copy the string to the generalPasteboard, as the [[UIPasteboard generalPasteboard] string] object, but the method causes the program to terminate.
- (void)copyResultToPasteboard {
NSString *message = self.resultTextView.text;
[UIPasteboard generalPasteboard].string = message;
[message release];
}
I think it's something to do with format, seeing as the method works if the message is set to a literal string, but resultTextView.text is just an NSString... I don't fully understand, can anyone help?