I have tried this :
- (void)willRotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration {
[self adjustViewsForOrientation:toInterfaceOrientation];
}
- (void)adjustViewsForOrientation:(UIInterfaceOrientation)orientation {
if (orientation == UIInterfaceOrientationLandscapeLeft || orientation == UIInterfaceOrientationLandscapeRight) {
intervalLabel.center = CGPointMake(100, 100);
}
else if (orientation == UIInterfaceOrientationPortrait || orientation == UIInterfaceOrientationPortraitUpsideDown) {
intervalLabel.center = CGPointMake(200, 200);
}
}
But it didn't work. however, if I do this it will move it
- (IBAction)sup:(id)sender {
intervalLabel.center = CGPointMake(100, 100);
}
BTW The label is made in storyboard and is outleted to my view did load and set to (weak, nonatomic) and the button is also made in storyboards and is just a standard IBAction