J JNG Member Licensed User Feb 4, 2017 #1 Hi I want to scroll scrollview by code. e.g. I have 10 panels in scroll view and by disabling the internal scroll property of scrollview I want to scroll according to need at which panel it should jump. disabling the touch is ok but moving around by code I am not finding any solution. p-l. suggest. regards jng
Hi I want to scroll scrollview by code. e.g. I have 10 panels in scroll view and by disabling the internal scroll property of scrollview I want to scroll according to need at which panel it should jump. disabling the touch is ok but moving around by code I am not finding any solution. p-l. suggest. regards jng
klaus Expert Licensed User Longtime User Feb 4, 2017 #2 You have two methods: ScrollPosition = xx smoth scrolling ScrollToNow(xx) fast scrolling I haven't tested it when scrolling is disabled. But you can enable scrolling just before the code scroll and disable scrolling just after the scroll. Upvote 0
You have two methods: ScrollPosition = xx smoth scrolling ScrollToNow(xx) fast scrolling I haven't tested it when scrolling is disabled. But you can enable scrolling just before the code scroll and disable scrolling just after the scroll.
J JNG Member Licensed User Feb 4, 2017 #3 Thanks I will give a try today it means I have to store the top position of each panel and then scroll according to the requirement. Anything related to this code will help more. regards jng Upvote 0
Thanks I will give a try today it means I have to store the top position of each panel and then scroll according to the requirement. Anything related to this code will help more. regards jng
klaus Expert Licensed User Longtime User Feb 4, 2017 #4 I have to store the top position of each panel... Click to expand... It depends on the height of the panels. If all panels have the the same height you can mutiliply the panel index by the panel height. Otherwise yes, you need to memorize the top values of the panels. Upvote 0
I have to store the top position of each panel... Click to expand... It depends on the height of the panels. If all panels have the the same height you can mutiliply the panel index by the panel height. Otherwise yes, you need to memorize the top values of the panels.
J JNG Member Licensed User Feb 4, 2017 #5 Its working now how can I limit the scroll between two positions. and enable the scroll between these position and deactivate the touch event of the scrollview regards jng Upvote 0
Its working now how can I limit the scroll between two positions. and enable the scroll between these position and deactivate the touch event of the scrollview regards jng
KMatle Expert Licensed User Longtime User Feb 4, 2017 #6 JNG said: now how can I limit the scroll between two positions. Click to expand... What are you going to achieve with it? I recreate the scrollview with the views I want the user to see (= limit) Upvote 0
JNG said: now how can I limit the scroll between two positions. Click to expand... What are you going to achieve with it? I recreate the scrollview with the views I want the user to see (= limit)
J JNG Member Licensed User Feb 4, 2017 #7 this is the requirement in my project because instead of creating four to five activities for this work I want to cover in one. Because my internal panels are of different height. to show the information I need to catch this event. Upvote 0
this is the requirement in my project because instead of creating four to five activities for this work I want to cover in one. Because my internal panels are of different height. to show the information I need to catch this event.
klaus Expert Licensed User Longtime User Feb 4, 2017 #8 Sorry, but I don't understand what exactly you want to do. Upvote 0
J JNG Member Licensed User Feb 4, 2017 #9 Hi! Its a information getting activity in which depending upon different selection I want to show different information in the panels and on selection I finally asked user to enter some information. This can be done in four to five activities but to avoid this I am using scrollview to achieve it. As you suggested every thing is working fine only now I want to catch the following how can I limit the scroll between two positions. and enable/disable the scroll between these position and deactivate/activate the touch event of the scrollview scrolled change position need to be controlled. Last edited: Feb 5, 2017 Upvote 0
Hi! Its a information getting activity in which depending upon different selection I want to show different information in the panels and on selection I finally asked user to enter some information. This can be done in four to five activities but to avoid this I am using scrollview to achieve it. As you suggested every thing is working fine only now I want to catch the following how can I limit the scroll between two positions. and enable/disable the scroll between these position and deactivate/activate the touch event of the scrollview scrolled change position need to be controlled.
Erel B4X founder Staff member Licensed User Longtime User Feb 5, 2017 #10 Handle the ScrollChanged position and call ScrollView.ScrollToNow if the position is outside of the allowed range. Upvote 0
Handle the ScrollChanged position and call ScrollView.ScrollToNow if the position is outside of the allowed range.