title: Problem with UIActivityIndicatorView on iPhone
body: <p>I want to show UIActivityIndicatorView on my iphone when it changing the view.
  I have written the following code:</p>
  
  <pre><code>- (void)viewDidLoad 
  {
  
    spinner = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhiteLarge];
    [spinner setCenter:CGPointMake(320/2.0, 460/2.0)]; // I do this because I'm in landscape mode
    [self.view addSubview:spinner];
  }
  </code></pre>
  
  <p>and on button's click event I want to change the view and in between that time I want to show that indicatorView So, I write</p>
  
  <pre><code>-(IBAction)buttonClick:(id)sender
  {
  
      [spinner startAnimating];
      ViewController *lController = [[ViewController alloc] initWithNibName: @"View" bundle:nil];
      self.viewController = lController;
      [lController release];
      //
      [[self mainController] dismissModalViewControllerAnimated:YES];
      [lViewController.view removeFromSuperview];
      [self.view addSubview: lController.view];
      [spinner stopAnimating];
   }
  </code></pre>
  
  <p>It is not displaying the Indicator, So plz tell me where I am wrong?</p>