Version

TemplateClosing Property

Event fired before the edit row template is closed.

This event is cancelable.

Syntax
'Declaration
 
Public Property TemplateClosing As String
public string TemplateClosing {get; set;}
Example
Me.WebDataGrid1.Behaviors.EditingCore.Behaviors.RowEditTemplate.RowEditingClientEvents.TemplateClosing = "WDG1_TemplateClosing"
this.WebDataGrid1.Behaviors.EditingCore.Behaviors.RowEditTemplate.RowEditingClientEvents.TemplateClosing = "WDG1_TemplateClosing";
// The client event TemplateClosing takes two parameters sender and e
// sender  is the object which is raising the event
// e is the CancelEditRowEventArgs

  function WDG1_TemplateClosing(sender, e) {

      //Returns the row whose template is about to be closed
      var row = e.get_row();
     
      //Returns the index of the row
      var index = row.get_index();

      if (!confirm("Are you sure you want to close the template for the row with index '" + index + "'?"))

      //Cancels the 'TemplateClosing' event
          e.set_cancel(true);  
  }
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also