G
Guest
Hi,
I copied the following code segment from the VS2005 Help on the MouseDown
event.
Private Sub panel1_MouseDown(ByVal sender As Object, ByVal e As
System.Windows.Forms.MouseEventArgs) Handles panel1.MouseDown
.....
Select Case e.Button
Case MouseButtons.Left <-Warning
eventString = "L"
Case MouseButtons.Right <-Warning
eventString = "R"
Case MouseButtons.Middle <-Warning
eventString = "M"
.....etc.
the warning message is: Warning Access of shared member, constant member,
enum member or nested type through an instance; qualifying expression will
not be evaluated.
I just don't see how MouseButtons.Right (etc) is refering to an instance.
The recomended fix is to replace MouseButtons with Windows.Forms.MouseButtons.
I copied the following code segment from the VS2005 Help on the MouseDown
event.
Private Sub panel1_MouseDown(ByVal sender As Object, ByVal e As
System.Windows.Forms.MouseEventArgs) Handles panel1.MouseDown
.....
Select Case e.Button
Case MouseButtons.Left <-Warning
eventString = "L"
Case MouseButtons.Right <-Warning
eventString = "R"
Case MouseButtons.Middle <-Warning
eventString = "M"
.....etc.
the warning message is: Warning Access of shared member, constant member,
enum member or nested type through an instance; qualifying expression will
not be evaluated.
I just don't see how MouseButtons.Right (etc) is refering to an instance.
The recomended fix is to replace MouseButtons with Windows.Forms.MouseButtons.