Hello,
I just began programming with Xcode, after I switched from php/javascript. I 'm beginning to understand the basics. But a certain warning keeps showing up, so I think I'm doing somethink very wrong.
I'm trying to pass a stringValue to a textField. Here's the code below:
header:
The Class:
When I compile this, I get this error (twice):
How do I solve this?
Thanks in regard,
Edwin
I just began programming with Xcode, after I switched from php/javascript. I 'm beginning to understand the basics. But a certain warning keeps showing up, so I think I'm doing somethink very wrong.
I'm trying to pass a stringValue to a textField. Here's the code below:
header:
Code:
#import <Cocoa/Cocoa.h>
@interface Controller : NSObject {
IBOutlet NSTextField *myField;
}
- (IBAction)check:(id)sender;
@end
The Class:
Code:
#import "Controller.h"
@implementation Controller
- (IBAction)check:(id)sender {
[myField setStringValue:"GOED"]; // <--- here's the error
}
@end
When I compile this, I get this error (twice):
warning: passing argument 1 of 'setStringValue:' from incompatible pointer type
How do I solve this?
Thanks in regard,
Edwin