G gkumar Active Member Licensed User Longtime User Jun 7, 2012 #1 I am using webservice to get the data having large number of elements. I need to set the scroll position for a scroll view after Parser_StartElement and Parse_EndElement event completion. How can I know whether these recurring parsing methods has been finished so that I can set the scroll position?
I am using webservice to get the data having large number of elements. I need to set the scroll position for a scroll view after Parser_StartElement and Parse_EndElement event completion. How can I know whether these recurring parsing methods has been finished so that I can set the scroll position?
Erel B4X founder Staff member Licensed User Longtime User Jun 7, 2012 #2 Once parsing has completed, the next line after SaxParser.Parse is executed. Upvote 0
G gkumar Active Member Licensed User Longtime User Jun 7, 2012 #3 I tried to put the scrollposition setting code after Parse line. But it didn't work. I am doing some condition checks and other bitmap loadings in the for around 500 rows for example. At that time, when the next line after Parse will be executed first before other things get completes. Any other way to achieve this? Upvote 0
I tried to put the scrollposition setting code after Parse line. But it didn't work. I am doing some condition checks and other bitmap loadings in the for around 500 rows for example. At that time, when the next line after Parse will be executed first before other things get completes. Any other way to achieve this?
Erel B4X founder Staff member Licensed User Longtime User Jun 7, 2012 #4 Try this code: Code: sv.ScrollPosition = x DoEvents sv.ScrollPosition = x Upvote 0
G gkumar Active Member Licensed User Longtime User Jun 7, 2012 #5 I Tried, its not working. One thing I observed is it works when I debug the code. Is there any way I can set little time delay for the execution of setting of scroll position. some delay equivalent to sleep() method? Upvote 0
I Tried, its not working. One thing I observed is it works when I debug the code. Is there any way I can set little time delay for the execution of setting of scroll position. some delay equivalent to sleep() method?
Erel B4X founder Staff member Licensed User Longtime User Jun 7, 2012 #6 You can use a short timer and set the scrolling position from the timer tick event (and then disable the timer). Upvote 0
You can use a short timer and set the scrolling position from the timer tick event (and then disable the timer).
G gkumar Active Member Licensed User Longtime User Jun 12, 2012 #7 As you mentioned I tried this via a timer. It worked! Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Jun 13, 2012 #8 Note that in v2.00 you will be able to use CallSubDelayed instead of the timer. Upvote 0