Note that there are some explanatory texts on larger screens.

plurals
  1. POI can't link button in .xib to method in .m file
    primarykey
    data
    text
    <p>(I've just learn objective-c for a short time. I still don't know how to generate UI elements through writting code now.)</p> <p>There is one button in .xib. There is one method in .m.</p> <p>I want to link these two things by ctrl-click "Touch up Inside" and "File's owner". However, no method shows up when I move the mouse cursor onto File's Owner's icon.</p> <p>The situation is like this: <a href="http://www.badongo.com/pic/13577347" rel="nofollow">http://www.badongo.com/pic/13577347</a></p> <p>the .h file:</p> <pre><code>#import &lt;UIKit/UIKit.h&gt; @interface ChangeViewController : UIViewController { } -(IBAction)goToSecondView:(id)sender; -(IBAction)goToCalculatorView:(id)sender; -(IBAction)test:(id)sender; @end </code></pre> <p>the .m file:</p> <pre><code>#import "ChangeViewController.h" #import "SecondViewController.h" #import "CalculatorViewController.h" @implementation ChangeViewController -(IBAction)goToSecondView:(id)sender { SecondViewController *secondViewController = [[SecondViewController alloc] initWithNibName:@"SecondViewController" bundle:nil]; [self.navigationController pushViewController:secondViewController animated:YES]; [secondViewController release]; } -(IBAction)goToCalculatorView:(id)sender { CalculatorViewController *calculatorViewController =[[CalculatorViewController alloc] initWithNibName:@"CalculatorViewController" bundle:nil]; [self.navigationController pushViewController:calculatorViewController animated:YES]; [calculatorViewController release]; } </code></pre> <p>Is there anything wrong? Thanks.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload