Infragistics(R) NetAdvantage(R) Windows Forms
RowSelectedEventArgs Class
Members  Example  See Also  E-mail your feedback on this topic.
Infragistics.Win.UltraWinGrid Namespace : RowSelectedEventArgs Class

Event parameters used for the AfterDropDown and AfterCloseUp event

Syntax

Visual Basic (Declaration) 
Public Class RowSelectedEventArgs 
   Inherits System.EventArgs
C# 
public class RowSelectedEventArgs : System.EventArgs 

Example

Following code prints out value of the ProductID field of the newly selected row every time a new row is selected in the UltraDropDown.

For an overview of how to handle events in Visual Basic or Visual C#, see Event Handlers in Visual Basic and Visual C#. For specific information and code examples illustrating how to consume events in your application, see Consuming Events in the .NET Framework Developer's Guide.

Visual BasicCopy Code
Imports Infragistics.Shared
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinGrid

  Private Sub UltraDropDown1_RowSelected(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.RowSelectedEventArgs) Handles ultraDropDown1.RowSelected

      ' RowSelected gets fired whenever a different row is selected in the UltraDropDown.			

      ' e.Row would be null if a row was unselected and no new row has been selected.
      If Not Nothing Is e.Row Then
          Debug.WriteLine("RowSelected: New row has been selected. ProductID = " & e.Row.Cells("ProductID").Value.ToString())
      Else
          Debug.WriteLine("RowSelected: No row is selected currently.")
      End If

  End Sub
C#Copy Code
using Infragistics.Shared;
using Infragistics.Win;
using Infragistics.Win.UltraWinGrid;
using System.Diagnostics;

private void ultraDropDown1_RowSelected(object sender, Infragistics.Win.UltraWinGrid.RowSelectedEventArgs e)
{

	// RowSelected gets fired whenever a different row is selected in the UltraDropDown.			

	// e.Row would be null if a row was unselected and no new row has been selected.
	if ( null != e.Row )
		Debug.WriteLine( "RowSelected: New row has been selected. ProductID = " + e.Row.Cells["ProductID"].Value.ToString( ) );
	else
		Debug.WriteLine( "RowSelected: No row is selected currently." );

}

See Also