I have to pass argument to java开发者_运维问答script function from Webview, but it is calling properly.
Thanks Vadivelu
Well ! I am just going to give an example. I know its too late ( almost a year :P )
[self.myWebView stringByEvaluatingJavaScriptFromString:[NSString stringWithFormat: @"window.scrollTo(0,%i);",kPageSize*(self.currentPage-1)]];
You can notice that, I have passed a parameter to javascript from objective-c.
This will cause webView to scroll some-where within a webView.
Hope it helps.
Note : Please do not forget to accept answer if it is helpful to you. ( as I noticed most of your questions are not accepted. )
精彩评论