Private Sub Button_Click(sender As Object, e As RoutedEventArgs) Dim group As OutlookBarGroup = xamOutlookBar1.Groups("Group1") If group IsNot Nothing Then group.IsSelected = True End If End Sub Private Sub Button_Click_1(sender As Object, e As RoutedEventArgs) Dim group As New OutlookBarGroup() group.SmallImage = New BitmapImage(New Uri("pack://application:,,,/32x32.png")) group.Header = "New Group" System.Diagnostics.Debug.WriteLine(group.Header + ".Location is " + group.Location) xamOutlookBar1.Groups.Add(group) System.Diagnostics.Debug.WriteLine(group.Header + ".Location is " + group.Location) End Sub
private void Button_Click(object sender, RoutedEventArgs e) { OutlookBarGroup group= xamOutlookBar1.Groups["Group1"]; if (group != null) { group.IsSelected = true; } } private void Button_Click_1(object sender, RoutedEventArgs e) { OutlookBarGroup group = new OutlookBarGroup(); group.SmallImage= new BitmapImage(new Uri("pack://application:,,,/32x32.png")); group.Header = "New Group"; System.Diagnostics.Debug.WriteLine(group.Header + ".Location is " + group.Location); xamOutlookBar1.Groups.Add(group); System.Diagnostics.Debug.WriteLine(group.Header + ".Location is " + group.Location); }
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, 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