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;
        }

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-09-21
  • 2022-01-09
  • 2021-10-23
  • 2022-01-11
  • 2021-10-31
  • 2022-02-16
猜你喜欢
  • 2021-12-14
  • 2022-12-23
  • 2021-09-16
  • 2022-12-23
  • 2022-12-23
  • 2021-08-14
  • 2022-12-23
相关资源
相似解决方案