Can someone answer me how to call one method into another in Objective C on Xcode
-
This isn't very clear. Please try a longer description. Perhaps you are talking about @selector ?Nimrod– Nimrod2010-10-12 04:02:56 +00:00Commented Oct 12, 2010 at 4:02
-
suppose in didFinishinLaunchingmethod i have to call -(IBAction)check; method ...how can i call it??vidhya jain– vidhya jain2010-10-12 04:08:19 +00:00Commented Oct 12, 2010 at 4:08
-
Please consider using a more descriptive title for your question. This one is very general.Johan Kool– Johan Kool2010-10-12 05:17:19 +00:00Commented Oct 12, 2010 at 5:17
Add a comment
|
4 Answers
The basic syntax for calling a method on an object is this:
[object method];
[object methodWithInput:input];
If methods returns value:
output = [object methodWithOutput];
output = [object methodWithInputAndOutput:input];
EDIT:
Here is a good example that how to call method from other class:
OBJECTIVE C - Objective-C call method on another class?
Example:
SomeClass* object = [[SomeClass alloc] init]; // Create an instance of SomeClass
[object someMethod]; // Send the someMethod message