Using NSTimer close UIAlertView
<p>I hope to use an UIAlertView prompt to reminder user some messages, the alerview will be closed automatically in 2 seconds.</p>

<p>my codes:</p>

<pre><code>IBOutlet UIAlertView *aUIAlertView;
</code></pre>

<p>....</p>

<pre><code>@property (retain,nonatomic)    IBOutlet UIAlertView *aUIAlertView;
</code></pre>

<p>....</p>

<pre><code>        UIAlertView * alert=[[UIAlertView alloc]
                             initWithTitle: @"Reminder"
                                   message: @"Message" 
                                  delegate:self
                                 cancelButtonTitle:nil
                             otherButtonTitles:nil, nil];

        [NSTimer scheduledTimerWithTimeInterval:2 
                                         target:self
                                       selector:@selector(timerFired1:)
                                       userInfo:nil
                                        repeats:NO]; 
        aUIAlertView=alert;
        [alert show];




- (void)timerFired1:(NSTimer *)timer {


    [aUIAlertView release];//I set the breakpoint here, aUIAlertView is not nill


}
</code></pre>

<p>timer was prompted, aUIAlertView is not nil.
but the alertview still displayed rather than was closed as I hoped.</p>

<p>Welcome any comment</p>

<p>Thanks</p>
