views:

692

answers:

1

I currently tried to force a wpf scrollbar to fire it's value changes for often, if the user presses the scroll-up or -down button, and holds the mouse button.

I tried to use a style like:

<Style TargetType="{x:Type RepeatButton}">
    <Setter Property="Interval" Value="20"/>
    <Setter Property="Delay" Value="20"/>
</Style>

Or to set the values directly:

scrollBar.Track.DecreaseRepeatButton.Delay = 20;
scrollBar.Track.DecreaseRepeatButton.Interval = 20;

scrollBar.Track.IncreaseRepeatButton.Delay = 20;
scrollBar.Track.IncreaseRepeatButton.Interval = 20;

I checked with mole that the values are present on the repeatbutton, but the buttons doesn't fire the command more often ...

Any ideas?

tia

A: 

I switched to storyboards and animations with it I solved my problem

Martin Moser