WheelScrollLines Property


WheelScrollLines Property

Location

My.Computer.Mouse.WheelScrollLines

Syntax

     Dim result As Integer = My.Computer.Mouse.WheelScrollLines 

Description

On systems that have a "mouse wheel" included on the installed mouse, the WheelScrollLines indicates how far the context should be scrolled when the wheel is rotated one position.

Usage at a Glance

  • This property is read-only.

  • This property is only valid in non-server applications.

  • An exception is thrown if the computer does not have an installed mouse.

  • An exception is thrown if the installed mouse does not include a mouse wheel.

  • Always use the My.Computer.Mouse.WheelExists property to detect the presence of a mouse wheel before using the WheelScrollLines property.

Example

The following example displays the scroll amount for each mouse wheel rotation position.

     If My.Computer.Mouse.WheelExists Then        MsgBox("Mouse wheel scroll amount is " & _           Abs(My.Computer.Mouse.WheelScrollLines) & ".")     Else        MsgBox("No mouse scroll wheel present.")     End If 

Related Framework Entries

  • Microsoft.VisualBasic.Devices.Mouse.WheelScrollLines Property

  • System.Windows.Forms.SystemInformation.MouseWheelScrollLines Property

See Also

ButtonsSwapped Property, Mouse Object, WheelExists Property




Visual Basic 2005(c) In a Nutshell
Visual Basic 2005 in a Nutshell (In a Nutshell (OReilly))
ISBN: 059610152X
EAN: 2147483647
Year: 2004
Pages: 712

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net