开发者

Edit a gridview inside a modalpopup without closing popup

I've got a modal popup (using ModalPopupExtender) working in a kind of master/detail view for a grid. When you click a button on one grid, it displays a popup window containing another grid of information, based on the row clicked in the first grid.

This works well... I've enabled editing in the grid that is popped up. When you click edit though, the popup window开发者_如何学JAVA disappears. If I click the display button in the first grid though to bring the popup window visible again it displays, and is now in edit mode.

Is there a way to make postbacks in the popup not close the popup?


Figured out a way to do this...

In the row command event for the gridview I just called Popup() for my modalpopup.

Works :)


I usually put an UpdatePanel around my ModalPopup contents. That way, everything that happens in the popup can be updated without doing a full page reload. It also makes it so that clicking "back" in the browser doesn't page through each thing that you did in the popup.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜