3.0.0

CheckedList

greetings! I've got a CheckedList with a few rows, each with their own value.

How can I programatically _uncheck_ one of these rows, knowing just its "index"?

I am not seeing much in the documentation. I can't tell if I should use "setItemSelected" or what. Everything I am trying is not working, so some extra advise to get me going in the right direction would be great.

I LOVE ActiveWidgets!!!

Thanks so much!
GroundWire
October 8,
Check UI.List selection Docs for checkedList reference:
http://www.activewidgets.com/aw.ui.list/selected-items.html
example:
var itemTextArray = ["Home", "Favorites", "Font size", "Search"];
var itemImageArray = ["home", "favorites", "fontsize", "search"];
    
var checkedList = new AW.UI.CheckedList;
checkedList.setId("checkedList1");
checkedList.setItemText(itemTextArray);
checkedList.setItemImage(itemImageArray);
checkedList.setItemCount(4);
    
checkedList.setSelectedItems([1,2])
document.write(checkedList);
    
var button = new AW.UI.Button;
button.setId("button2");
button.setControlText("Select fourth Item");
button.setControlImage("favorites");
button.onControlClicked = function(event){
checkedList.setSelectedItems([3])
checkedList.getItemsTemplate().refresh();
  }
document.write(button);
October 9,
That page you reference doesn't have nearly as much information as you put in your post.

So what I am seeing (but it's not actually said anywhere), is that you CANNOT simply "unselect" a single entry in a CheckedList.

Instead, you must tell it all of the elements that ARE checked - and you would leave out the one you want to uncheck from this array.

Very interesting.. I didn't expect this. Is there any way to get it to function the way I first described?

Thanks!
Joel
October 10,

This topic is archived.

See also:


Back to support forum

Search

Version 2

Looking for AW 2.6 ?
The old site is here.