HelpInverting Mouse Button

Posts 1–2 of 2 · Page 1 of 1
Inverting Mouse Button
What is the VB code to invert mouse?
First add this import to your class (on top of your class code):

Code:
Imports System.Runtime.InteropServices
Then declare this function (inside the class):

Code:
<DllImport("user32.dll")> _
Public Shared Function SwapMouseButton(bSwap As Int32) As Int32
End Function
And then call this function from your code like this:

To swap:
Code:
SwapMouseButton(1)
Back to normal state:
Code:
SwapMouseButton(0)
Posts 1–2 of 2 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Need help?