I tried this code in the view controller, but it didn't work. Why is that?
- (void)viewDidLoad {
[self setBackgroundColor:[UIColor colorWithRed:1.0 green:1.0 blue:1.0 alpha:1.0]];
[super viewDidLoad];
}
I tried this code in the view controller, but it didn't work. Why is that?
- (void)viewDidLoad {
[self setBackgroundColor:[UIColor colorWithRed:1.0 green:1.0 blue:1.0 alpha:1.0]];
[super viewDidLoad];
}
You should set background color to the view, not to its controller:
[self.view setBackgroundColor:[UIColor colorWithRed:1.0 green:1.0 blue:1.0 alpha:1.0]];