Results 1 to 2 of 2
- 05-05-2011, 01:43 PM #1
Member
- Join Date
- Mar 2011
- Posts
- 35
- Rep Power
- 0
how to focus dojo slider to a particular value and then disabling dojo slider so that
How to focus dojo slider to a particular value (say 2.5 )on the slider and then disabling dojo slider so that value not changes on clicking on the dojo slider?ie i want to focus dojo slider to a particular value and then make it disable.
Java Code:<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html dir="ltr"> <head> <style type="text/css"> body, html { font-family:helvetica,arial,sans-serif; font-size:90%; } </style> <script src="../cmic/dojo/dojo/dojo.js" djConfig="parseOnLoad: true"> </script> <script type="text/javascript"> dojo.require("dijit.form.Slider"); dojo.require("dijit.form.TextBox"); // this we only include to make the textinput look prettier dojo.addOnLoad(function() { var slider = new dijit.form.HorizontalSlider({ name: "slider", value: 0, minimum: 0, maximum: 10, intermediateChanges: true, style: "width:700px;", onChange: function(value) { dojo.byId("sliderValue").value = value; } }, "slider"); }); </script> <link rel="stylesheet" type="text/css" href="../cmic/dojo/dijit/themes/claro/claro.css" /> </head> <body class=" claro "> <div id="slider" intermediateChanges="true" showButtons="false" style="width:400px;color:#606060;"> <ol dojoType="dijit.form.HorizontalRuleLabels" container="topDecoration" style="height:1.5em;color:#585858;font-size:75%;color:gray;"> <li>0 </li> <li> 2 </li> <li> 4 </li> <li> 6 </li> <li> 8 </li> <li>10 </li> </ol> <ol dojoType="dijit.form.HorizontalRuleLabels" container="topDecoration" style="height:1.5em;font-size:90%;color:#606060;margin:-1em 0px 0px 7.00em;"> <li> Outstanding </li> <li> Highly effective </li> <li>   Effective </li> <li>                        Needs Improvement </li> <li>                               Not Acceptable </li> <li> </li></ol> </div> <p> <input type="text" id="sliderValue" dojoType="dijit.form.TextBox" /> </p> <script type="text/javascript"> dojo.addOnLoad(function() { if (document.pub) { document.pub(); } }); </script> </body> </html>
- 05-05-2011, 01:47 PM #2
Similar Threads
-
Reversing dojo slider to make it slide from right to left rather left to right as giv
By gurpreet.singh in forum JavaServer Pages (JSP) and JSTLReplies: 1Last Post: 05-05-2011, 01:49 PM -
Image Slider Help
By matthew707 in forum New To JavaReplies: 1Last Post: 01-04-2011, 04:37 PM -
progress bar with slider
By paddala in forum AWT / SwingReplies: 1Last Post: 10-17-2010, 01:48 PM -
how to zoom using slider
By kumar_gemi in forum New To JavaReplies: 0Last Post: 07-11-2009, 10:06 PM -
How to use Slider in SWT
By Java Tip in forum SWTReplies: 0Last Post: 07-02-2008, 08:05 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks