P PCastagnetti Member Licensed User Longtime User Nov 2, 2016 #1 Assuming you have a very long page, I was wondering if you could move to a specific location on the page (perhaps using an Anchor Tag?) I tried it with page.CurrentRow command, but I did not get any results Thank you Last edited: Nov 2, 2016
Assuming you have a very long page, I was wondering if you could move to a specific location on the page (perhaps using an Anchor Tag?) I tried it with page.CurrentRow command, but I did not get any results Thank you
alwaysbusy Expert Licensed User Longtime User Nov 3, 2016 #2 CurrentRow should actually be hidden. It's an internal variable. You could use something like this in the ConnectPage() method after page.FinishedLoading: B4X: ... Dim img As ABMImage img.Initialize(page, "img", "../images/alainbailleul.png", 1) page.Cell(6,1).AddComponent(img) ... page.Refresh ' IMPORTANT! page.FinishedLoading 'IMPORTANT Dim script As String = $"$("body").animate({ scrollTop: $('#${img.ID}').offset().top }, 1000);"$ ' <-- scroll animated to img.ID page.ws.Eval(script, Null) page.ws.Flush ' IMPORTANT Upvote 0
CurrentRow should actually be hidden. It's an internal variable. You could use something like this in the ConnectPage() method after page.FinishedLoading: B4X: ... Dim img As ABMImage img.Initialize(page, "img", "../images/alainbailleul.png", 1) page.Cell(6,1).AddComponent(img) ... page.Refresh ' IMPORTANT! page.FinishedLoading 'IMPORTANT Dim script As String = $"$("body").animate({ scrollTop: $('#${img.ID}').offset().top }, 1000);"$ ' <-- scroll animated to img.ID page.ws.Eval(script, Null) page.ws.Flush ' IMPORTANT
P PCastagnetti Member Licensed User Longtime User Nov 3, 2016 #3 it works perfectly thank you Upvote 0