Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

moving image control..

0 views
Skip to first unread message

Diep Huynh

unread,
Nov 29, 1999, 3:00:00 AM11/29/99
to

Hi,

I try to make a sliding bar by using 2 image controls (1 for a
horizontal bar, the other for button slider).
I can move the button slider to the end of the bar but I cannot move it
back. I mean I can move the control to the right but not to the left.
Does any one know how to do it?

Thanks in advance.
Diep


Ken Halter

unread,
Nov 29, 1999, 3:00:00 AM11/29/99
to
If it's moving at all, you're doing something right.... Post some sample code to get more info..

Diep Huynh <dhu...@fyi-net.com> wrote in message news:3842FE59...@fyi-net.com...

Diep Huynh

unread,
Nov 29, 1999, 3:00:00 AM11/29/99
to
I don't know if I do it right or not :) but here is my code

Private Sub imgButton_DragOver(Source As Control, X As Single, Y As Single, State As Integer)
 
      Source.Move (Source.Left + X)

End Sub

X value is alway positive, that's why the control alway moves to the right, I think!

Diep

Ken Halter

unread,
Nov 29, 1999, 3:00:00 AM11/29/99
to
I just tried your code.....
If image1 = slider (long horizontal image control) and image2 = picture to slide (thumb), the following will work.
 
'==========
Private Sub Image1_DragOver(Source As Control, X As Single, Y As Single, State As Integer)
   Source.Move Image1.Left + X
End Sub
'==========
 
Diep Huynh <dhu...@fyi-net.com> wrote in message news:38430514...@fyi-net.com...

Diep Huynh

unread,
Nov 29, 1999, 3:00:00 AM11/29/99
to
Thanks, but sometime it works, sometime it doesn't move any where.
Also, even I set the thumb's BorderStyle = 0 - None, when I drag it, its border still visible.  Do you know how to fix this problem?

Thanks again.
 

Ken Halter wrote:

I just tried your code.....If image1 = slider (long horizontal image control) and image2 = picture to slide (thumb), the following will work. '==========Private Sub Image1_DragOver(Source As Control, X As Single, Y As Single, State As Integer)

   Source.Move Image1.Left + X
End Sub
'========== 

Diep Huynh <dhu...@fyi-net.com> wrote in message news:38430514...@fyi-net.com...I don't know if I do it right or not :) but here is my code

0 new messages