title: NSTimer timerWithTimeInterval: not working
body: <p>I've created a test application with timer before implementing it in my project.
  It was the first time I'm using timer.
  But the issue is when I implemented timer using <code>[NSTimer timerWithTimeInterval: target: selector: userInfo: repeats: ];</code> , it is not working.
  Here is my code,
  Interface:</p>
  
  <pre><code>@interface uialertViewController : UIViewController
  {
  
      NSTimer *timer;
  }
  
  -(void)displayAlert;
  -(void)hideandview;
  @end
  </code></pre>
  
  <p>Implementation:</p>
  
  <pre><code>@implementation uialertViewController
  - (void)viewDidLoad {
  
      [self displayAlert];
      [super viewDidLoad];
  }
  
  
  -(void)displayAlert{
  
      timer = [NSTimer timerWithTimeInterval:1 target:self selector:@selector(hideandview) userInfo:nil repeats:NO];
  
      alert = [[UIAlertView alloc] initWithTitle:@"testing" message:@"hi hi hi" delegate:nil cancelButtonTitle:@"continue" otherButtonTitles:nil];
      [alert show];
  
  
  
  
      [alert release];
      alert = nil;
  
  }
  
  -(void)hideandview{
  
      NSLog(@"triggered");
  
      [alert dismissWithClickedButtonIndex:0 animated:YES];
  
      [alert release];
  
      [self displayAlert];
  }
  
  @end
  </code></pre>
  
  <p><strong>Then I Changed</strong> <code>[NSTimer timerWithTimeInterval: target: selector: userInfo: repeats: ];</code> <strong>with</strong> <code>[NSTimer scheduledTimerWithTimeInterval: target: selector:userInfo: repeats: ];</code> <strong>, It is working</strong>. What was the issue with <code>timerWithTimeInterval:</code> ? Am I mising anything in my first implementation ? Thanks in advance.</p>