'Declaration Public Function GetItemsByKey( _ ByVal key As String _ ) As UltraExplorerBarItem()
public UltraExplorerBarItem[] GetItemsByKey( string key )
Imports System.Diagnostics Imports Infragistics.Win Imports Infragistics.Win.UltraWinExplorerBar Private Sub Button34_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button34.Click ' For each group, get an array of all Items with a Key of 'DrawingTool' and display the ' items that were retrieved. Dim group As UltraExplorerBarGroup For Each group In Me.ultraExplorerBar1.Groups ' Get an array of all items in the Group with a Key of 'DrawingTool'. Dim items As UltraExplorerBarItem() = group.GetItemsByKey("DrawingTool") ' Display the items that were retrieved. If (Not items Is Nothing) Then Dim i As Integer For i = 0 To items.Length - 1 Dim item As UltraExplorerBarItem = items.GetValue(i) If (Not item Is Nothing) Then Debug.WriteLine("Item '" + item.Text + "' found with a Key of 'DrawingTool'") End If Next End If Next End Sub
using System.Diagnostics; using Infragistics.Win; using Infragistics.Win.UltraWinExplorerBar; private void button34_Click(object sender, System.EventArgs e) { // For each group, get an array of all Items with a Key of 'DrawingTool' and display the // items that were retrieved. foreach(UltraExplorerBarGroup group in this.ultraExplorerBar1.Groups) { // Get an array of all items in the Group with a Key of 'DrawingTool'. UltraExplorerBarItem [] items = group.GetItemsByKey("DrawingTool"); // Display the items that were retrieved. if (items != null) { for (int i = 0; i < items.Length; i++) { UltraExplorerBarItem item = items.GetValue(i) as UltraExplorerBarItem; if (item != null) Debug.WriteLine("Item '" + item.Text + "' found with a Key of 'DrawingTool'"); } } } }
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