I have an application on which I have a tab control with two tabs. When a
user double-clicks on an item in tab1 of my tabs collection, tab2 becomes
the visible tab. (tabImageTabs.S electedIndex = 1) When they double-click on
the content in tab2, they are taken back to tab1.
(tabImageTabs.S electedIndex = 0)
When tab1 is restored, I have lost the position of the scrollbar and the
user must re-scroll to get back to where they were. I've tried setting the
scroll value (grab the verticlescroll value when leaving tab1 and assigning
it that value when I go back, but it doesn't seem to work.
Any ideas?
Here's the code I use to capture the position of the scrollbar when changing
to tab2:
ScrollBarLocati on = tabThumbNails.V erticalScroll.V alue
tabImageTabs.Se lectedIndex = 1
Here's the code I am using to move back to the tab1 with the verticle scroll
value set:
tabImageTabs.Se lectedIndex = 0
tabThumbNails.V erticalScroll.V alue = ScrollBarLocati on
(At this point, I get my tab1 back in front, but the scroll bar is back at
the top.)
user double-clicks on an item in tab1 of my tabs collection, tab2 becomes
the visible tab. (tabImageTabs.S electedIndex = 1) When they double-click on
the content in tab2, they are taken back to tab1.
(tabImageTabs.S electedIndex = 0)
When tab1 is restored, I have lost the position of the scrollbar and the
user must re-scroll to get back to where they were. I've tried setting the
scroll value (grab the verticlescroll value when leaving tab1 and assigning
it that value when I go back, but it doesn't seem to work.
Any ideas?
Here's the code I use to capture the position of the scrollbar when changing
to tab2:
ScrollBarLocati on = tabThumbNails.V erticalScroll.V alue
tabImageTabs.Se lectedIndex = 1
Here's the code I am using to move back to the tab1 with the verticle scroll
value set:
tabImageTabs.Se lectedIndex = 0
tabThumbNails.V erticalScroll.V alue = ScrollBarLocati on
(At this point, I get my tab1 back in front, but the scroll bar is back at
the top.)
Comment