I try to show/hide view by tap using nstimer.

```
    @interface
        @property (nonatomic, retain)NSTimer *timer;
        UIView *view;
        @implementation
        view.hiden=YES;
        - (void)handleTap:(UITapGestureRecognizer *)sender{
        if([timer isValid)]{
timer.invalidate;///that gives me _EXC_BAD_ACCESS
}
        view.hiden=NO;
        timer = [NSTimer scheduledTimerWithTimeInterval:3.0
                                                     target:self
                                                   selector:@selector(targetMethod)
                                                   userInfo:nil
                                                    repeats:NO];

        }
        -(void)targetMethod{
        view.hiden=YES;
        }

```

If you understand something of this code, you can see the problem. If I tap once and wait 3 seconds, everthing is fine.But if I tap on it and tap again after 1.5 seconds, it should make another timer case and hide it after 3 seconds, but it hide it after 1.5 seconds, because old one is firing.

As you can see, I tried to invaliditate it but gives me error.

So how can I destroy it in proper way?