i have several uiwebviews with a considerable amount of text. when making a window.scrollto (as well as a window.scroll) javascript call to the webviews, they scroll to an incorrect location. e.g. i want to scroll to 12000 but the webview will scroll to 10149 every time instead. while another one will scroll to 10250. yet another one, which i want to scroll to 22000 or so, will scroll to 20230 every time instead.
this only happens on the device and not in the simulator.
i am making the call in webViewDidFinishLoad.
i have tried making the call multiple times in a row with no better results. it seems that whatever value the particular webview scrolls to is the farthest it is willing to go when using the scrollto call. there is no problem when giving it a lesser value to scroll to. it's just if you pass that magic number, whatever it is for that webview, it will go no further.
i have several uiwebviews with a considerable amount of text. when making a window.scrollto (as well as a window.scroll) javascript call to the webviews, they scroll to an incorrect location. e.g. i want to scroll to 12000 but the webview will scroll to 10149 every time instead. while another one will scroll to 10250. yet another one, which i want to scroll to 22000 or so, will scroll to 20230 every time instead.
this only happens on the device and not in the simulator.
i am making the call in webViewDidFinishLoad.
i have tried making the call multiple times in a row with no better results. it seems that whatever value the particular webview scrolls to is the farthest it is willing to go when using the scrollto call. there is no problem when giving it a lesser value to scroll to. it's just if you pass that magic number, whatever it is for that webview, it will go no further.
any input would be much appreciated
Hi,
I am trying to scroll webview to an offset when a button click occurs [Page up and Page down buttons], for that i have to know the following things,
i) Scrollable content height,
ii) How to move the webview to an offset of the screen.
i have several uiwebviews with a considerable amount of text. when making a window.scrollto (as well as a window.scroll) javascript call to the webviews, they scroll to an incorrect location. e.g. i want to scroll to 12000 but the webview will scroll to 10149 every time instead. while another one will scroll to 10250. yet another one, which i want to scroll to 22000 or so, will scroll to 20230 every time instead.
this only happens on the device and not in the simulator.
i am making the call in webViewDidFinishLoad.
i have tried making the call multiple times in a row with no better results. it seems that whatever value the particular webview scrolls to is the farthest it is willing to go when using the scrollto call. there is no problem when giving it a lesser value to scroll to. it's just if you pass that magic number, whatever it is for that webview, it will go no further.
any input would be much appreciated
Hi,
I am using following code for save current position.