views:

497

answers:

1

Hello guys,

i'm developing an app that saves html files locally on iPhone file system, then load them in UIWebView.. i want to be able to zoom or double tap programmatically on the UIWebView, i tried searching for javascript code, but i could only scroll

also tried the webview transform, but didn't work out for me.

so, i found this method sendAction:to:from:forEvent:

http://developer.apple.com/iphone/library/documentation/UIKit/Reference/UIApplication_Class/Reference/Reference.html#jumpTo_26

in the UIApplication class, that can send actions to controls.

does anybody know, how to send the double tap action programmatically to a UIWebView on a certain x,y ??

appreciate your help!

+1  A: 

get the UIWebview's subview which is a UIScrollview

UIScrollView *sview = [[webview subviews] objectAtIndex:0];

Then use zoom methods on that.

maxpower