开发者

Clear the data from the control after the insert the row?

开发者 https://www.devze.com 2022-12-23 19:53 出处:网络
I\'m using aspxgridview and after adding operation by using RowInserting event and I don\'t use the gridView.CancelEdit();

I'm using aspxgridview and after adding operation by using RowInserting event and I don't use the

gridView.CancelEdit();

becuase I need the addform still apperaing to insert another row.

My problem is : how can I clean the data from the control in the addform until I can insert the开发者_StackOverflow中文版 new data for the second row ??

thanks


I got the solve of my problem by using ASPxClientEdit.ClearEditorsInContainer :

clientsideevents EndCallback ="function(s, e) {
if (s.cpIsUpdated) { ASPxClientEdit.ClearEditorsInContainer(ContainerId); } }"

and add the following code after the RowInserting event:

        gridView.JSProperties["cpIsUpdated"] = true;

thanks

0

精彩评论

暂无评论...
验证码 换一张
取 消