2X faster development
The ultimate WinForms UI toolkit to boost your development speed.
Validate the text entered for new labelThe NodeEditorValidating event of the TreeViewAdv control to validate the node's label text entered by the user. C# private void treeViewAdv1_NodeEditorValidating(object sender, Syncfusion.Windows.Forms.Tools.TreeNodeAdvCancelableEditEventArgs e) { if(e.Label.Length == 0) { //Cancel the label edit action, inform the user, and place the node in edit mode again. e.Cancel = true; MessageBox.Show("The label cannot be blank", "Node Label Edit"); //To end editing mode,call: e.ContinueEditing = false; } } VB Private Sub treeViewAdv1_NodeEditorValidating(ByVal sender As Object, ByVal e As Syncfusion.Windows.Forms.Tools.TreeNodeAdvCancelableEditEventArgs) If e.Label.Length = 0 Then ' Cancel the label edit action, inform the user, and place the node in edit mode again. e.Cancel = True MessageBox.Show("The label cannot be blank", "Node Label Edit") ' To end editing mode,call: e.ContinueEditing = false; End If End Sub
|
2X faster development
The ultimate WinForms UI toolkit to boost your development speed.
This page will automatically be redirected to the sign-in page in 10 seconds.