This is a migrated thread and some comments may be shown as answers.

Disable Value Change

1 Answer 24 Views
Slider
This is a migrated thread and some comments may be shown as answers.
Vasu
Top achievements
Rank 1
Vasu asked on 05 Jul 2012, 06:03 PM
Hi,

How can I prevent the user from changing the slider value? One way to do this is by disabling the slider, but the look and feel isn't good.

Thanks

Vasu

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 06 Jul 2012, 04:28 AM
Hi Vasu,

You can cancel the value change on OnClientValueChanging event as follows.

JS:
<script type="text/javascript">
 function OnClientValueChanging(sender, args)
  {
    args.set_cancel(true);
  }
</script>

Thanks,
Shinu.
Tags
Slider
Asked by
Vasu
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or