私はこれに似た他の質問を見ましたが、どの解決策も使用できませんでした。
.h
@property (assign) IBOutlet NSTextView *commandOutput;
.m
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification
{
Command *aCommand = [[Command alloc] init];
[self setCommand:aCommand];
if (self.commandOutput) NSLog(@"textView is not nil");
[self.commandOutput setString:@""];
}
私が受け取るエラーメッセージは次のとおりです。-[NSScrollView setString:]: unrecognized selector sent to instance 0x100608630
私もそれを見ます:textView is not nil