RadGrid for ASP.NET

RadGrid Send comments on this topic.
IsFromDetailTable Property
See Also  Example
Telerik.WebControls Namespace > GridNeedDataSourceEventArgs Class : IsFromDetailTable Property


Boolean property which specifies whether the GridTableView instance passed in the NeedDataSource handler is the MasterTableView or detail table.   

 

Namespace: Telerik.WebControls
Assembly: RadGrid (in RadGrid.dll)

Syntax

Visual Basic (Declaration) 
Public ReadOnly Property IsFromDetailTable As Boolean
Visual Basic (Usage)Copy Code
Dim instance As GridNeedDataSourceEventArgs
Dim value As Boolean
 
value = instance.IsFromDetailTable
C# 
public bool IsFromDetailTable {get;}

Return Value

boolean

Example

C#Copy Code
protected void RadGrid1_NeedDataSource(object source, Telerik.WebControls.GridNeedDataSourceEventArgs e)
{
  
if (!e.IsFromDetailTable)
  {
     
//MasterTableView referenced here
  }
  
else
  {
     
//detail table view referenced here
  }
}
    
Visual BasicCopy Code
Private Sub RadGrid1_NeedDataSource(ByVal source As Object, ByVal e As GridNeedDataSourceEventArgs) Handles RadGrid1.NeedDataSource
   If Not e.IsFromDetailTable Then
     'MasterTableView referenced here
   Else
     'detail table referenced here
   End If
End Sub

Remarks

Meaningful in scenarios when hierarchy is bound inside the NeedDataSource handler only

Requirements

Platforms: Windows 2000, Windows XP Professional, Windows Server 2003 family

See Also