这是因为Image6_Click没有Button这个参数嘛,写程序不能随你高兴的呀,编译没错估计是因为你没设强制变量定义解决的办法是用Private Sub Image1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)

解决方案 »

  1.   

    对不起是
    Private Sub Image1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
      

  2.   

    以下两种方法都可以:
    1.Private Sub Image1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
        If Button = 2 Then Unload Me
    End Sub2.Private Sub Image1_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
        If Button = 2 Then Unload Me
    End Sub你的问题在于:
    click事件中,找不到Button 参数。
      

  3.   

    以下两种方法都可以:
    1.Private Sub Image1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
        If Button = 2 Then Unload Me
    End Sub2.Private Sub Image1_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
        If Button = 2 Then Unload Me
    End Sub你的问题在于:
    click事件中,找不到Button 参数。