I don’t know why I am getting this problem.
Details – I have a tab-bar controller in my application. On one tab I have a form which contains some buttons. I am setting up the titles of these buttons. Now, when I change tabs and come back to the same tab, all the button titles appear darken.
I am attaching screen-shots as well.
Any help would be appreciated.
Thank you !!



EDIT : Here is the code of how I am creating the buttons –
-(void)viewWillAppear:(BOOL)animated
{
float yFrame =310.0f;
for(int i =0;i<7;i++){
openPickerButton=[UIButton buttonWithType:UIButtonTypeCustom];
openPickerButton.frame = CGRectMake(29.0, yFrame+10.0, 280.0, 48.0);
openPickerButton.tag=i;
openPickerButton.backgroundColor=[UIColor clearColor];
[openPickerButton setTitle:[formButtonTitle objectAtIndex:openPickerButton.tag] forState:UIControlStateNormal];
openPickerButton.titleLabel.font=[UIFont fontWithName:@"Helvetica" size:16];
[openPickerButton setTitleColor:[UIColor lightGrayColor] forState:UIControlStateNormal];
openPickerButton.contentHorizontalAlignment=UIControlContentHorizontalAlignmentLeft;
openPickerButton.showsTouchWhenHighlighted = YES;
[openPickerButton addTarget:self action:@selector(PickChoreButtonAction:) forControlEvents:UIControlEventTouchUpInside];
[setPreferencesFormScrollView addSubview:openPickerButton];
yFrame+=60.0f;
}
}
Well in viewDidLoad your objects get called once.(As soon as the view get loaded.
Stop)
In viewWillAppear they get called every time the view appears.