2013-07-10 41 views
0

我在頁面中使用了iframe。在回發中避免iframe在asp.net中刷新

對於每個回發事件,iframe的內容都會刷新。

我不想刷新上iface postback事件的內容,iframe只能在頁面加載時間(!ispostback)時才調用。

我在我的iframe中有一個很大的計算,所以如果它每次加載父頁面(主頁面)回發事件時都沒有使用iframe。

所以請在這個問題上幫助我。

回答

0

使用的UpdatePanel

<asp:UpdatePanel ID="UpdatePanel3" runat="server" UpdateMode="Always"> 
    <ContentTemplate> 
     content that only you want to postback 
    </ContentTemplate> 
</asp:UpdatePanel> 

refrence http://msdn.microsoft.com/en-IN/library/system.web.ui.updatepanel%28v=vs.100%29.aspx

+0

其實對每一個事件的IsPostBack的iframe也越來越令人耳目一新。如果我在我的父頁面中做任何點擊事件,這個iframe不應該得到刷新。我不想刷新我在IFrame中的頁面。 – kesavakumar