Pergunta

I have a scroll viewer over my tab control e.g.

<ScrollViewer>
   <TabControl>
        <!-- my tabs -->

However in one of the tabs there is a list view and I was wondering if there is a way to disable / turn off the scroll viewer just for this tab?

Foi útil?

Solução

You can use a binding between the ScrollViewer.VerticalScrollBarVisibility and the TabControl.SelectedTab properties. Then apply a converter that disables the scroll bar of the ScrollViewer when the current tab is the tab containing the list view.

Outras dicas

Do you really want the ScrollViewer outside of the TabControl? You could set the ScrollViewer in each pane you need it. Advantage: you only have a ScrollViewer where you want it and you don't scroll the complete TabControl and you always will see the headers.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top