Question:
Objective-C and Cocoa newbie question?
Chase
2008-12-22 07:17:58 UTC
I'm using Xcode/interface builder 3 to build a simple practice application. I've created a custom class called "Checker" and am trying to define one of my methods. I'm trying to use the takeStringValueFrom method found in the documentation, and I get two errors in the same spot saying that it is undeclared. I thought apple methods were declared from the imported files or something. I found the location where the documentation says it is declared, and even tried importing that file, but the same thing happens. How and where do I declared this method?? Here's the code:

---------------------
//This is the Checker.h file

#import

@interface Checker : NSObject {
IBOutlet id textField;
}
- (IBAction)checkPass:(id)sender;
@end
----------------------

----------------------
//This is the Checker.m file

#import "Checker.h"

@implementation Checker

- (IBAction)checkPass:(id)sender {

[textField - (void)takeStringValueFrom : (id)textField];

/*This is where error appears. takeStringValueFrom undeclared (first use in this function*/

}
@end

-----------------------

I hope somebody can help. It's irritating.
Three answers:
EdSF
2008-12-22 07:23:26 UTC
Don't have an answer for you since I'm not into this particular language. I can only give you a tip:



You'll be better off joining a Group that is **specifically** targeted for the language. By "Group", I'm referring to a discussion forum of like-minded programmers.



This way you get a more focused/targeted audience - and by extension a better/quicker answer.
anonymous
2016-10-25 12:32:43 UTC
quite some web pages for Mac builders, I placed a pair that ought to wish to position you interior the perfect route. on project that Mac builders are quite fewer on the floor than abode abode windows ones. the most suitable position to communicate ought to correctly be the Mac forums for any recommend there'll be experienced Mac purchasers who can coach you strategies to there.
anonymous
2008-12-22 07:20:53 UTC
i dont know


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...