标签:cts val box ide depend listbox else gen win
public override System.Windows.Style SelectStyle(object item, System.Windows.DependencyObject container) { if (ContainerStyle1 == null) return null; TCheckListBoxItem citem = container as TCheckListBoxItem; TCheckListBox listView = ItemsControl.ItemsControlFromItemContainer(container) as TCheckListBox; int index =listView.ItemContainerGenerator.IndexFromContainer(container); if (index % 2 == 0) { citem.IsOddIndex = true; //IsOddIndex.Value = true; } else { citem.IsOddIndex = false; // IsOddIndex.Value = false; } return ContainerStyle1; }
通过 listboxitem 查找属于listbox第几条数据
标签:cts val box ide depend listbox else gen win
原文地址:http://www.cnblogs.com/m7777/p/6070620.html