Question : silverlight 3.0 mouse wheel support

I am trying to figure out how to scroll the body of my application in Silverlight 3.0.  I can see that there is an event to handle it, but every post I read says, "you get an integer value from the mouse wheel, now do something with it".  OK, do WHAT with it?

Here is the code I have, and the event is fired.  I just dont know what to do with the delta value to get my application to scroll:

public Constructor()
{  
   this.MouseWheel += new MouseWheelEventHandler(POQueryView_MouseWheel);
}

void POQueryView_MouseWheel(object sender, System.Windows.Input.MouseWheelEventArgs e)
{
      int delta = e.Delta;    //Now what?
}

Answer : silverlight 3.0 mouse wheel support

That would make it useless, sorry about posting a read-only property.

I found the code below from http://cid-50f67260092b35c3.skydrive.live.com/browse.aspx/Public/Silverlight?sa=271106396

It uses an sv.ScrollToVerticalOffset() function.  "childScrollViewer" is the name for their ScrollViewer.  
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
var delta = eventArgs.WheelDelta; 
delta *= scrollAmount; 
var newOffset = childScrollViewer.VerticalOffset - delta; 
if (newOffset > childScrollViewer.ScrollableHeight)
      newOffset = childScrollViewer.ScrollableHeight; 
else if (newOffset < 0)
      newOffset = 0; 
childScrollViewer.ScrollToVerticalOffset(newOffset);
Random Solutions  
 
programming4us programming4us