UIButton *button = [[UIButton alloc] initWithFrame:CGRectMake(0.0, 0.0, 300, 50)];
[button setTitle:@"hi" forState:UIControlStateNormal];
[button setBackgroundColor:[UIColor blackColor]];
[self.view addSubview:button];
[UIView beginAnimations:nil context:nil];
[UIView setAnimationDuration:2.5];
button.backgroundColor = [UIColor whiteColor];
[UIView commitAnimations];