开发者

RadGrid InsertCommand event repeats on every page refresh

I'm using MasterTableEditForm for inserting rows in RadGrid. In edit form I have a button with commandname = "Perf开发者_如何学运维ormInsert" property, for inserting new row.

In C#, I'm using InsertCommand event for my custom insert logic. After this, my MasterTableEditForm is closing, but every time when I refresh page, InsertCommand is handling again with commandname = "PerformInsert" property and Insert operation is repeating.

So what can I do, to avoid multiple InsertCommand handling?

thanks!


I think the problem is that you must detach event after handling logic for Insert event, if that is not a problem you must seperate logic for refreshing your model from acion for your button, because method for the button should not be runnnig on refresh

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜