UITapGestureRecognizer *singleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(fingerTapped:)];
[self.view addGestureRecognizer:singleTap];
- (void)fingerTapped:(UITapGestureRecognizer *)tap{
[self.view endEditing:YES];
}
UITapGestureRecognizer *singleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(fingerTapped:)];
[self.view addGestureRecognizer:singleTap];
- (void)fingerTapped:(UITapGestureRecognizer *)tap{
[self.view endEditing:YES];
}