Imports System.Diagnostics Imports Infragistics.Win Imports Infragistics.Win.UltraWinExplorerBar Private Sub Button37_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button37.Click ' Look for the first StateButton type Item that is Checked and in view and display its text. Dim group As UltraExplorerBarGroup For Each group In Me.ultraExplorerBar1.Groups Dim item As UltraExplorerBarItem For Each item In group.Items If (item.SettingsResolved.Style = ItemStyle.StateButton AndAlso _ item.Checked = True AndAlso _ item.IsInView = True) Then Debug.WriteLine("The first checked item that is in view is: '" + item.Text + "'") Exit For End If Next Next End Sub
using System.Diagnostics; using Infragistics.Win; using Infragistics.Win.UltraWinExplorerBar; private void button37_Click(object sender, System.EventArgs e) { // Look for the first StateButton type Item that is Checked and in view and display its text. foreach(UltraExplorerBarGroup group in this.ultraExplorerBar1.Groups) { foreach(UltraExplorerBarItem item in group.Items) { if (item.SettingsResolved.Style == ItemStyle.StateButton && item.Checked == true && item.IsInView == true) { Debug.WriteLine("The first checked item that is in view is: '" + item.Text + "'"); break; } } } }
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2