
关于vb打开窗体的问题
form1.show这样打开没问题。但:setnewopen=newform1newopen.show这样新打开的窗体不响应鼠标的mousedown事件,怎么办是新打开的...
form1.show 这样打开没问题。
但:
set newopen = new form1
newopen.show
这样新打开的窗体不响应鼠标的mousedown事件,怎么办
是新打开的窗体上的图片(image1),不是窗体
我是想拖动图片来使整个窗体移动
Private Sub tanbg_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Dim dl&
dl& = GetCursorPos(MyPoint)
If Button = 1 Then
dl& = MoveWindow(tan.hwnd, MyPoint.X - Movex, MyPoint.Y - Movey, MyRect.Right - MyRect.Left, MyRect.Bottom - MyRect.Top, -1)
End If
End Sub 展开
但:
set newopen = new form1
newopen.show
这样新打开的窗体不响应鼠标的mousedown事件,怎么办
是新打开的窗体上的图片(image1),不是窗体
我是想拖动图片来使整个窗体移动
Private Sub tanbg_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Dim dl&
dl& = GetCursorPos(MyPoint)
If Button = 1 Then
dl& = MoveWindow(tan.hwnd, MyPoint.X - Movex, MyPoint.Y - Movey, MyRect.Right - MyRect.Left, MyRect.Bottom - MyRect.Top, -1)
End If
End Sub 展开
1个回答
展开全部
响应的.要在原form1的mousedown事件中添加代码才行.
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询