I'm using this method, but it works only for my UIView subclass. If I tap on UITextView or UIButton or on any other object it's not display coordinates. How to get coordinates of tap on UITextView? And why this happening?
- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event {
UITouch *userTouch = [[event allTouches] anyObject];
CGPoint currentPos = [userTouch locationInView:self.view];
NSLog(@"Coordinates: (%f,%f)", currentPos.x, currentPos.y);
}