Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Slider Control
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
01275347
Message ID:
01275365
Views:
40
>I'm working on a slider control:
>http://www.geocities.com/kevin.marois/slider/dragdrop1.jpg
>
>I can't seem to get the thumb to work right.
>
>See this:
>http://www.geocities.com/kevin.marois/slider/test.zip
>
>Anyone know how to go about this?


Hi Kevin,

Great Idea !

Just replace the code you have in your MouseMove() event from the CommandButton inside the container with the code below:
LPARAMETERS nButton, nShift, nXCoord, nYCoord

IF nButton <> 1 
	RETURN
ENDIF


IF nXCoord <= This.Parent.Left
	nXCoord = This.Parent.Left
ENDIF

IF nXCoord >= This.Parent.Left + This.Parent.Width - This.Width
	nXCoord = This.Parent.Left + This.Parent.Width - This.Width 
ENDIF

This.Left = nXCoord - This.Parent.Left

RETURN
Hope this helps

Cesar
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform