tags:

views:

16

answers:

2

i want to change the font color of the label at some time interval .can anyone tell how to do it ?

+1  A: 
label.textColor = [UIColor colorWithRed:(60 / 255.0) green:(159 / 255.0) blue:(159 / 255.0) alpha:1.0];

Assuming you are having problem with the color, not with the timer :-)

taskinoor
A: 

Hi, you could do something along the lines of:

//start timer in didLoad or something
[NSTimer scheduledTimerWithTimeInterval:10 target:self selector:@selector(myTimerMethod) userInfo:nil repeats:NO];

-(void)myTimerMethod:(NSTimer*)timer 
{
   //this will be executed after 10 seconds and change the label lblName text color to 128, 0, 0
   lblName.textColor = [UIColor colorWithRed:0.5 green:0.0 blue:0.0 alpha:1.0];
}

Hope this helps

clocKwize