views:

189

answers:

0

When I added a toolbar below a UITableView I want to show an activity indicator and label for few minutes to get values from a URL.

I added this code in my project:

NSArray *toolbarItems = [NSArray arrayWithObjects:[[UIBarButtonItem alloc] initWithCustomView:actview], [[UIBarButtonItem alloc] initWithCustomView:label], nil];
[toolbar setItems:toolbarItems animated:YES];
[actview startAnimating];

In iPhone Simulator version 2.0 it works fine, but in simulator version 3.0, it works the first time only.

How can I fix this?