Prevent slider from moving if cursor is not on control


Is there a way to prevent slider movement after user clicks the mouse but goes off the control?
I need to capture both mousedown and mouseup events. If user clicks the mouse then lets go when the mouse is off the slider control, only the mouseout event gets fired.

I need to not allow the slider to move when mouse is off the control and have the mouseup event fire off before the mouseout event.



such a problem may occurs if the slider is initialized before the page content is loaded. Try to move slider intialization to the window onload handler:

window.onload = function(){
var myslider = new dhtmlxSlider(…);


Thanks for the reply.

I tried initializing slider in window.onload event but I’m still able to move the slider. Other suggestions?

Could you provide the demo to reproduce the problem ?

How do I change where the cursor is on my Microsoft Word Document? Basically, on my word document I’ve written a paragraph of writing and then i’ve drawn two spider diagrams using text boxes, however i can’t seem to click or place my cursor underneath the spider diagrams to carry on writing. This also means I cant seem to get a new page without moving my spider diagrams on the first page.