简体   繁体   中英

Syntax for setting checkbox value(as checked) in dojo dynamically

How to set the value of a check-box to checked dynamically using dojo ? In dojo toolkit site I saw it was written to use key value pair for setting the checkboxWidget but am unsure about the approach. Can someone please suggest?

Here is my approach but it doesnt work .How can I fix this?:

 checkboxWidget.set("","checked");

如果使用set为属性赋值,则第一个参数是属性名称,后跟值。

checkboxWidget.set("checked", checkedValue);

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM