バージョン

TemplateOpening プロパティ

編集行テンプレートが開く前に発生したイベント。

このイベントはキャンセルできます。

シンタックス
'宣言
 
Public Property TemplateOpening As String
public string TemplateOpening {get; set;}
使用例
Me.WebDataGrid1.Behaviors.EditingCore.Behaviors.RowEditTemplate.RowEditingClientEvents.TemplateOpening = "WDG1_TemplateOpening"
this.WebDataGrid1.Behaviors.EditingCore.Behaviors.RowEditTemplate.RowEditingClientEvents.TemplateOpening = "WDG1_TemplateOpening";
// The client event TemplateOpening takes two parameters sender and e
// sender  is the object which is raising the event
// e is the CancelEditRowEventArgs

   function WDG1_TemplateOpening(sender, e) {

       //Returns the row whose template is about to open
       var row = e.get_row();

       //Returns the index of the row
       var index = row.get_index();

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

       //Cancels the 'TemplateOpening' event
           e.set_cancel(true);
   }
参照