I have added the button in storyboard like the following picture:
I also have added the code in the header file as shown in the following code:
#import <UIKit/UIKit.h>
@interface ViewController : UIViewController <UIPickerViewDataSource,UIPickerViewDelegate>
@property (strong, nonatomic) IBOutlet UIButton *Up;
@property (strong, nonatomic) IBOutlet UIButton *Back;
@property (strong, nonatomic) IBOutlet UIButton *Left;
@property (strong, nonatomic) IBOutlet UIButton *Ok;
@property (strong, nonatomic) IBOutlet UIButton *Right;
@property (strong, nonatomic) IBOutlet UIPickerView *DeviceSelect;
@end
I want to add the style for the UIButton
in the .m file as shown in the following code:
self.Up = [UIButton buttonWithType:UIButtonTypeRoundedRect];
[self.view addSubview:_Up];
But it seems its not working. The UIButton
didn't change anything.
Did I miss something?
I am new to iOS , Please teach me... Thanks in advance.