'宣言 Public ReadOnly Property GalleryTool As GalleryTool
public GalleryTool GalleryTool {get;}
Imports System Imports System.Windows Imports Infragistics.Windows.Ribbon Namespace MyNamespace Public Partial Class MyWindow Inherits XamRibbonWindow Public Sub New() InitializeComponent() End Sub Private Sub CheckGalleryTool() Dim gallery As GalleryTool = Me.galleryGroup.GalleryTool End Sub End Class End Namespace
using System; using System.Windows; using Infragistics.Windows.Ribbon; namespace MyNamespace { public partial class MyWindow : XamRibbonWindow { public MyWindow() { InitializeComponent(); } private void CheckGalleryTool() { // Gallery tool GalleryTool gallery = this.galleryGroup.GalleryTool; } } }