Alessandro Posted April 28, 2015 Posted April 28, 2015 Hello everyone. I´m use XE5 and uniGUI 0.95. I have a form having various fields, and in the form I´m use the TUniScrollBox to behave them. However, this component does not have the ".VertScrollBar.Position: = n". What happens ... every time I open an existing record, to read all the fields, the Scroll is positioned at the end of the form, which requires the user to have to roll the scroll bar to the top to start watching the information. I tried using the very form of scrollBar, but when using the command 'Form.VertScrollBar.Position: = 0' gives an external exception. Does anyone have a solution for that I place the beginning of the Scroll? Thank you. Alessandro. Quote
aln02 Posted April 28, 2015 Posted April 28, 2015 Hi.Perhaps it will help you: UniSession.AddJS(UniScrollBox.JSName+'.getTargetEl().scrollTo("top");'); - for Desktop and UniSession.AddJS(UnimScrollBox.JSName+'.getScrollable().getScroller().scrollTo(0, 0);'); - for Mobile 1 Quote
Kattes Posted June 2, 2022 Posted June 2, 2022 For me the following code for mobile environment worked: UniSession.AddJS(UnimScrollBox1.JSName+'.getScrollable().scrollTo(0, 0);'); // Scroll to Top Quote
Sherzod Posted June 2, 2022 Posted June 2, 2022 28 minutes ago, Kattes said: For me the following code for mobile environment worked: UniSession.AddJS(UnimScrollBox1.JSName+'.getScrollable().scrollTo(0, 0);'); // Scroll to Top Also you can use this code: Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.