-
Mar 3rd, 2012, 07:04 AM
#1
Thread Starter
PowerPoster
[VB6] - simulation click on IDE
i know that i can activate a timer on IDE(it's the few of events that we can use on IDE).
Code:
Private Sub tmrIDEScrollClick_Timer()
Call GetCursorPos(MousePositions)
If MousePositions.x = ScrollingVertical.Left Then MsgBox ""
End Sub
(these is my code test)
but i recive an error message: "error 53": file path no found: user". to be honest i don't know what these error message have to do lol
i need some sugestions. thanks
-
Mar 3rd, 2012, 10:25 AM
#2
Thread Starter
PowerPoster
Re: [VB6] - simulation click on IDE
ok.. i put it to work:
Code:
Private Sub tmrIDEScrollClick_Timer()
If Ambient.UserMode = True Then tmrIDEScrollClick.Enabled = False
'Vertical scroll
If CollisionPrecise(MouseX(UserControl.hWnd), MouseY(UserControl.hWnd), 1, 1, ScrollingVertical.Left, 0, 17, 17) = True And GetKeyState(VK_LBUTTON) < 0 Then
If ScrollingVertical.Value - 10 <= ScrollingVertical.Min Then
ScrollingVertical.Value = ScrollingVertical.Min
Else
ScrollingVertical.Value = ScrollingVertical.Value - 10
End If
ElseIf CollisionPrecise(MouseX(UserControl.hWnd), MouseY(UserControl.hWnd), 1, 1, ScrollingVertical.Left, ScrollingVertical.Height - 17, 17, 17) = True And GetKeyState(VK_LBUTTON) < 0 Then
If ScrollingVertical.Value + 10 >= ScrollingVertical.Max Then
ScrollingVertical.Value = ScrollingVertical.Max
Else
ScrollingVertical.Value = ScrollingVertical.Value + 10
End If
'Horizontal scroll
ElseIf CollisionPrecise(MouseX(UserControl.hWnd), MouseY(UserControl.hWnd), 1, 1, 0, ScrollingHorizontal.Top, 17, 17) = True And GetKeyState(VK_LBUTTON) < 0 Then
If ScrollingHorizontal.Value - 10 <= ScrollingHorizontal.Min Then
ScrollingHorizontal.Value = ScrollingHorizontal.Min
Else
ScrollingHorizontal.Value = ScrollingHorizontal.Value - 10
End If
ElseIf CollisionPrecise(MouseX(UserControl.hWnd), MouseY(UserControl.hWnd), 1, 1, ScrollingHorizontal.Width - 17, ScrollingHorizontal.Top, 17, 17) = True And GetKeyState(VK_LBUTTON) < 0 Then
If ScrollingHorizontal.Value + 10 >= ScrollingHorizontal.Max Then
ScrollingHorizontal.Value = ScrollingHorizontal.Max
Else
ScrollingHorizontal.Value = ScrollingHorizontal.Value + 10
End If
End If
End Sub
the code works fine. but i still with 1 problem. every timers that i used in my controls and are activated in IDE i see 1 bug.
when we write object.propertyname is showed a problem. the dot show us the property\method list, but the timer can hide these list. can i avoid these bug?
-
Mar 6th, 2012, 01:55 PM
#3
Thread Starter
PowerPoster
Re: [VB6] - simulation click on IDE
can i create a variable for controle the usercontrol?
(in these case i need a public in a module)
-
Apr 9th, 2012, 01:11 PM
#4
Thread Starter
PowerPoster
Re: [VB6] - simulation click on IDE
can anyone tell me what usercontrol events works on IDE?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|