uiscrollview - iOS scroll view childs are not getting touched -


i'm new ios i'm getting problem scroll view. scroll view having image views subviews. whenever i'm trying touch image inside scroll view, scroll view touch getting enable instead of subview. how resolve problem? thanks

add tap gesture recognizer scroll view enabling touch inside scroll view:

uitapgesturerecognizer *singltap = [[uitapgesturerecognizer alloc] initwithtarget:self action:@selector(methodname:)]; singltap.cancelstouchesinview = no; [scrollviewname addgesturerecognizer:singltap]; 

then write code in specified method.

-(void)methodname:(uitapgesturerecognizer *)gesture {      //your code here } 

thats all


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -