Unable to create IBAction connections in Xcode 5 Storyboard

This seems to be a very basic problem, but it upsets me to the end and stops progress. When I click and drag from UIButtonor UIStepperto the view controller, the option to add IBActionconnections is not specified.

The view controller is called BuyNowVC, and in mine BuyNowVC.hI have:

@interface BuyNowVC : UIViewController {
    IBOutlet UIButton *buyButton;
    IBOutlet UIStepper *myStepper;
}

@property (nonatomic, retain) IBOutlet UIButton *buyButton;
@property (nonatomic, retain) IBOutlet UIStepper *myStepper;

- (IBAction)buttonPressed;
- (IBAction)stepperPressed;

And in BuyNowVC.m:

@synthesize buyButton;
@synthesize myStepper;

- (IBAction)buttonPressed {
    NSLog(@"Button pressed!");
}

- (IBAction)stepperPressed {
    NSLog(@"Stepper pressed!");
}

I definitely drag and drop Ctrl onto the view controller itself, but the only parameters I get with UIButtonand UIStepperare Action Segue: push, modal, custom. No sign buttonPressedor stepperPressed.

Edit

, VC, UIButton Segue View ( ), , , , .

+3
3

, BuyNow.m BuyNowVC.m?

, UIButton IBAction , , , " " " , UIButton .

, ".... Segue: push, modal, custom. buttonPressed stepperPressed.". , control UIButton , IBAction - .

:

enter image description here

, , :

"Custom Class" UIButton .

, UIButton " " .

ScreenShot:

, . UIButton. , , "Action Connection" "Hi" control -Dragging to it.

:

1.) UIButton .

2.) (3- ) " " UIButton.

enter image description here

, :

enter image description here

+5

It is how I normally do it

:

,

1) ( "" )

2)

3) ViewController, . 10.

+1

... @interface . @implementation, .

, . "": (

+1

All Articles