Hi,
I am new to iphone development. I want to set an activity indicator which is loaded on my custom button. please guide me.(Example: App store --> Search-->Show 25 more(on click)).
Thanks.
Hi,
I am new to iphone development. I want to set an activity indicator which is loaded on my custom button. please guide me.(Example: App store --> Search-->Show 25 more(on click)).
Thanks.
Add the Activity indicator as a subview of the button:
// Create spinner
UIActivityIndicatorView *myIndicator = [[UIActivityIndicatorView alloc]
initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhite];
// Position the spinner
[myIndicator setCenter:CGPointMake(50.0, 30.0)];
// Add to button
[myButton addSubview:myIndicator];
// Start the animation
[myIndicator startAnimating];