How to set touch events in subviews?
i have a main view controller with two subview in it,one is note-view and other one is share-view . When i click the cell of the tableview that is in the main-view controller ,it popups note-view,there is button in the note-view ,if the user tap the button it pop sup a another subview ,the share-view  .But i need to close the share view when the user tap the note-view.Is that possible to implement a touch event in a subview ?
I have done this coding but result is error
in viewdidload

    NotesView *label =[[NotesView alloc]init];
        UITapGestureRecognizer *tapGesture =
        [[[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(NoteTap)]     autorelease];
        [label addGestureRecognizer:tapGesture];
        [tapGesture release];
then

    -(void)NoteTap
    {
        UIView *langview = (UIView *)[self.view viewWithTag:120]; 
        //ViewWithTag Number should be same as used while allocating
        [langview removeFromSuperview];
    }
How to set touch events in subviews?
===

i have a main view controller with two subview in it,one is note-view and other one is share-view . When i click the cell of the tableview that is in the main-view controller ,it popups note-view,there is button in the note-view ,if the user tap the button it pop sup a another subview ,the share-view  .But i need to close the share view when the user tap the note-view.Is that possible to implement a touch event in a subview ?
I have done this coding but result is error
in viewdidload

    NotesView *label =[[NotesView alloc]init];
        UITapGestureRecognizer *tapGesture =
        [[[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(NoteTap)]     autorelease];
        [label addGestureRecognizer:tapGesture];
        [tapGesture release];
then

    -(void)NoteTap
    {
        UIView *langview = (UIView *)[self.view viewWithTag:120]; 
        //ViewWithTag Number should be same as used while allocating
        [langview removeFromSuperview];
    }