Synchronize Listview Scrollbars

A

andi rickenbach

Hello,

i have two listviews next to each other on a form. I would like to
synchronize both vertical scrollbars of the two listviews with one scrollbar
(for example VScrollBar). How can I do that?

Thank you very much.
 
S

sreeraj r

You can use 'ScrollToVerticalOffset' method(in wpf Scroll Viewer).
Believe the following code snippet will help you

private void ScrollViewer1_ScrollChanged(object sender, ScrollChangedEventArgs e)
{
ScrollViewer2.ScrollToVerticalOffset(e.VerticalOffset);

}



Happy Coding
Sree
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top