2017-07-18 91 views
0

我有一些文本字段的模態對話框。在父窗口中,我有一箇中繼器,如果點擊中繼器的item_command,模式對話框的文本字段中輸入的數據將被清除。後退事件清除對話框中的數據。所有這些都在同一個更新面板內。我已經嘗試把它們放在不同的更新面板中,但沒有工作。我可以如何解決這個問題?VB.NET數據從父窗口上的模式彈出窗口發回

+0

您缺少的代碼。另外,什麼是「中繼器」?你的問題不清楚。 –

+0

你是否在另一個更新面板? –

+0

@LorenzMeyer轉發器是一個asp.net控件 –

回答

1

對中繼器和模式對話框使用兩個不同的更新面板。也可以將UpdateMode作爲對話框的更新面板,並將AsyncPostBackTrigger用於例如相同的更新面板 。

<asp:UpdatePanel ID="UpdatePanel2" runat="server"> 
<ContentTemplate> 
.....Repeater Control goes here........ 
</ContentTemplate> 
</asp:UpdatePanel> 
........other html goes here........ 
<asp:UpdatePanel ID="UpdatePanel2" runat="server" UpdateMode="Conditional"> 
<ContentTemplate>      
<div id="divadvance" runat="server"> 
<asp:TextBox ID="txtAmount" runat="server" Style="width: 85%;"></asp:TextBox> 
<input type="button" runat="server" id="btSearch" /> 
</div> 
</ContentTemplate> 
<Triggers> 
<asp:AsyncPostBackTrigger ControlID="btSearch" EventName="ServerClick" /> 
</Triggers> 
</asp:UpdatePanel> 
+0

非常感謝你。它的工作 –