steve589 Posted January 15, 2018 Share Posted January 15, 2018 Hi, how can I scroll programatically in UniURLFrame? I used to do this in javascript like so: elTo.offsetParent.scrollTop = elTo.offsetTop; But this does not work in UniURLFrame... Any ideas? Thanks for help steve Link to comment Share on other sites More sharing options...
Sherzod Posted January 16, 2018 Share Posted January 16, 2018 Hi, One possible solution, can you try to use this approach ?!: UniURLFrame1.JSInterface.JSCall('iframe.contentWindow.document.scrollingElement.scrollTo', ['top', 0]); Best regards, Link to comment Share on other sites More sharing options...
steve589 Posted January 16, 2018 Author Share Posted January 16, 2018 Yes, this works from outside the frame! From inside the frame it would be (added to the HTML at UniForm.Create): ' parent.' + UniURLFrame1.JSName + '.iframe.contentWindow.document.scrollingElement.scrollTop = 0;' or ' parent.' + UniURLFrame1.JSName + '.iframe.contentWindow.document.scrollingElement.scrollTop = elTo.offsetParent';' where elTo is the element to scroll to. with javascript from outside the frame (f.i. from Ext ClientEvent, added to the ClientEvent at UniForm.Create): ' var elTo = ' + UniURLFrame1.JSName + '.iframe.contentWindow.document.getElementById("some_ID");' + ' if (elTo) {' + ' UniURLFrame1.JSName + '.iframe.contentWindow.document.scrollingElement.scrollTop = elTo.offsetTop;' + ' }' Excellent support! Thanks a lot! Steve Link to comment Share on other sites More sharing options...
SISBLU Software Posted March 23, 2023 Share Posted March 23, 2023 Error: O13.iframe.contentWindow.document.scrollingElement.scrollTo("top",0); Link to comment Share on other sites More sharing options...
NizamUlMulk Posted July 26, 2023 Share Posted July 26, 2023 Hi. I am having problems with TUniURLFrame component, it stays inaccessible or "read only" when clicking over a scroll bar or lugging it, more frequently when crSize cursor is showed over the scroll bar, then the application showed into the frame stay inaccesible. How can fix it? My version is 1.50.0.1482 Link to comment Share on other sites More sharing options...
Sherzod Posted July 26, 2023 Share Posted July 26, 2023 Hello, Can you test it on the latest versions, and upgrade to the latest versions? Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now