コメントページを作成しようとしていますが、コメントを追加するスペースに UITextView を使用し、コメントが印刷される場所に UILabel を使用しています。コメントをページに「貼り付ける」にはどうすればよいでしょうか。現在、UITextView に何か新しいものが入力されるたびに書き換えられ続けています。どうもありがとう!
EDIT2:
これが私のコードです...サーバーなどにデータを保存する必要がありますか?
私のヘッダーファイルでは:
{
IBOutlet UITextView *commentBox;
IBOutlet UILabel *commentsDisplay;
}
-(IBAction)submit;
私の実装ファイルでは:
-(IBAction)submit{
NSMutableString *tmpStr = [[NSMutableString alloc]initWithString:commentsDisplay.text];
[tmpStr stringByAppendingString:[NSString stringWithFormat:@"%@", commentBox.text]];
[commentsDisplay setText:tmpStr];
commentBox.text = @"";
[commentBox resignFirstResponder];
}