'宣言 Public ReadOnly Property ActiveRow As UltraGridRow
public UltraGridRow ActiveRow {get;}
Imports Infragistics.Shared Imports Infragistics.Win Imports Infragistics.Win.UltraWinGrid Imports System.Diagnostics Private Sub Button37_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles button37.Click If Me.ultraGrid1.ActiveRow Is Me.ultraGrid1.DisplayLayout.ActiveRow Then Debug.WriteLine("UltraGrid.ActiveRow and DisplayLayout.ActiveRow are the same.") Else Debug.Assert(False, "UltraGrid.ActiveRow can not be different.") End If End Sub
using Infragistics.Shared; using Infragistics.Win; using Infragistics.Win.UltraWinGrid; using System.Diagnostics; private void button37_Click(object sender, System.EventArgs e) { if ( this.ultraGrid1.ActiveRow == this.ultraGrid1.DisplayLayout.ActiveRow ) { Debug.WriteLine( "UltraGrid.ActiveRow and DisplayLayout.ActiveRow are the same." ); } else { Debug.Assert( false, "UltraGrid.ActiveRow can not be different." ); } }