'宣言 Public Property ActiveGroup As UltraExplorerBarGroup
public UltraExplorerBarGroup ActiveGroup {get; set;}
TabStopプロパティがFalseに設定されているためにコントロールがフォーカスを受け取らない場合、または現在フォーカスを持つGroupがない場合は、このプロパティはnullを返します。
このプロパティを設定すると、その Group がアクティブ Group になり、さらに Style が「ExplorerBar」の場合にはフォーカスを示す四角形が Group Header に表示されます。
Imports System.Diagnostics Imports Infragistics.Win Imports Infragistics.Win.UltraWinExplorerBar Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button2.Click ' If there is an ActiveGroup set, set the ActiveItem to the first item within the ' ActiveGroup. If (Not Me.ultraExplorerBar1.ActiveGroup Is Nothing AndAlso Me.ultraExplorerBar1.ActiveGroup.Items.Count > 0) Then Me.ultraExplorerBar1.ActiveItem = Me.ultraExplorerBar1.ActiveGroup.Items(0) Return End If ' If there is an ActiveItem set, set the ActiveGroup to the group containing the item. If (Not Me.ultraExplorerBar1.ActiveItem Is Nothing) Then Me.ultraExplorerBar1.ActiveGroup = Me.ultraExplorerBar1.ActiveItem.Group Return End If End Sub
using System.Diagnostics; using Infragistics.Win; using Infragistics.Win.UltraWinExplorerBar; private void button2_Click(object sender, System.EventArgs e) { // If there is an ActiveGroup set, set the ActiveItem to the first item within the // ActiveGroup. if (this.ultraExplorerBar1.ActiveGroup != null && this.ultraExplorerBar1.ActiveGroup.Items.Count > 0) { this.ultraExplorerBar1.ActiveItem = this.ultraExplorerBar1.ActiveGroup.Items[0]; return; } // If there is an ActiveItem set, set the ActiveGroup to the group containing the item. if (this.ultraExplorerBar1.ActiveItem != null) { this.ultraExplorerBar1.ActiveGroup = this.ultraExplorerBar1.ActiveItem.Group; return; } }