Data ListIs Valid Property
This property can be used to query the current row template to see if it is valid
Definition
Namespace: EWSoftware.ListControls
Assembly: EWSoftware.ListControls (in EWSoftware.ListControls.dll) Version: 2024.12.31.0
Returns true if it is valid or there are no items, false if it is not
Assembly: EWSoftware.ListControls (in EWSoftware.ListControls.dll) Version: 2024.12.31.0
C#
public bool IsValid { get; }VB
Public ReadOnly Property IsValid As Boolean
GetC++
public:
property bool IsValid {
bool get ();
}F#
member IsValid : bool with getProperty Value
BooleanReturns true if it is valid or there are no items, false if it is not
Remarks
This is useful in situations where the normal validating events are fired after certain
other events (i.e. tree view and data grid item selection events).
Example
C#
// Prevent a change of the tree view node if the current row
// template in the data list is not valid.
private void tree_BeforeSelect(object sender, TreeViewCancelEventArgs e)
{
e.Cancel = !dataList.IsValid;
}VB
' Prevent a change of the tree view node if the current row
' template in the data list is not valid.
Private Sub tree_BeforeSelect(sender As Object, e As TreeViewCancelEventArgs) _
Handles tree.BeforeSelect
e.Cancel = Not dataList.IsValid
End SubC++
No code example is currently available or this language may not be supported.F#
No code example is currently available or this language may not be supported.