rt
先谢谢了

解决方案 »

  1.   

    VB的控件没有这个事件,你可以用变通的方便来完成..比如在窗体的MOUSEMOVE事件里加入你要的代码..
      

  2.   

    Private Sub Image1_Click()
    '''''''查找营业员
        FrmQuery营业员.Show 1
        Text2.Text = FrmQuery营业员.employee_id
    End SubPrivate Sub Image1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
        Line1(2).Visible = True
        Line1(3).Visible = True
        Line2(2).Visible = True
        Line2(3).Visible = True
    End SubPrivate Sub Image3_Click()
    '''''''''''''查找进货单
    FrmQuery分配.Show 1
    Text1.Text = FrmQuery分配.fp_id
    End SubPrivate Sub Image3_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
        
         Line1(0).Visible = True
        Line1(1).Visible = True
        Line2(0).Visible = True
        Line2(1).Visible = True
    End Sub
    Private Sub Frame1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
       Line1(0).Visible = False
       Line1(1).Visible = False
       Line2(0).Visible = False
       Line2(1).Visible = False
       
       Line1(2).Visible = False
       Line1(3).Visible = False
       Line2(2).Visible = False
       Line2(3).Visible = False
    End Sub
      

  3.   

    Private Declare Function ReleaseCapture Lib "USER32" () As Long
    Private Declare Function SetCapture Lib "USER32" (ByVal hWnd As Long) As Long
    Private Sub Command1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
        Dim MouseOver As Boolean
        Dim i As Integer, II As Integer
        MouseOver = (0 <= X) And (X <= Command1.Width) And (0 <= Y) And (Y <= Command1.Height)
        If MouseOver Then
            SetCapture Command1.hWnd
        Else
            ReleaseCapture
        End If
    End Sub
      

  4.   

    假设你的picture控件是放在窗体上则如下代码:
    dim test as boolean
    Private Sub Picture1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    test=ture
    End Sub
    Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    test = False
    End Sub
      

  5.   

    To mndsoft(枕善居主) 
    SetCapture这个API函数是做什么的呀?