GridView中的CommandField和ButtonField
在GridView控件中,一个是CommandField按钮,做选择用的,还有一个是ButtonField按钮,触发事件的时候,CommandField的Page.IsPostBack为true,ButtonField的Page.IsPostBack却为false
解决方案:
- To solve it you can:
- Remove update panel
- Or change buttontype to Button or Link
- Or only convert commandfield to Templatefield