~~~~~ModalPopupExtender显示问题请教

finer 2011-04-18 04:41:21
1,GridView内添加了一个ModalPopupExtender,此时点击GridView内的触发ModalPopupExtender的控件,显示会是正常的。
2,当GridView外层添加一个Div时,此时再点击GridView内的触发ModalPopupExtender的控件,显示就只局限在这个Div内,请教此时我要做如何调整?

谢谢
...全文
147 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
子夜__ 2011-04-18
  • 打赏
  • 举报
回复
finer 2011-04-18
  • 打赏
  • 举报
回复
部分代码如下:
<div style="height:250px; width:100%; background-color:#FFFFFF; margin:5px auto; position:relative; overflow:auto">
<asp:GridView ...>
<columns>
<asp:TemplateField headertext="培訓對象">
<itemstyle HorizontalAlign="2" width="60"/>
<itemtemplate>
<%#Eval("TrainingTarget")%>
</itemtemplate>
<edititemtemplate>
<table>
<tr>
<td>
<asp:TextBox runat="server" ID="tTarget" Text=<%#Eval("TrainingTarget")%> Width="160"></asp:TextBox>
</td>
<td>
<asp:ImageButton runat="server" ID="ibtnTarget" ImageUrl="images/dept.png" Height="20" Width="20"/>
</td>
</tr>
</table>
<asp:Panel ID="Panel3" runat="server" Style="display: none;" CssClass="modalPopup" backColor="#EFE6DA" Height="360" Width="220">
<asp:Panel ID="Panel4" runat="server" Style="cursor: move;background-color:#DBD7C8;border:solid 0px Gray;color:Black; height:30px; width:200px">
<div style="width:200px; background-color:#DBD7C8; padding:0px;"><asp:LinkButton ID="CancelButton" runat="server" Text="X"/></div>
<br />
<asp:UpdatePanel runat="server" UpdateMode="Conditional">
<ContentTemplate>
<table>
<tr>
<td></td>
<td align="center">部門</td>
<td width="20"></td>
<td></td>
</tr>
<tr>
<td></td>
<td>
<asp:ListBox runat="server" ID="lbDept03" SelectionMode="Multiple" Rows="16" DataSourceID="sds03" DataTextField="P002_03" DataValueField="P002_02" >
</asp:ListBox></td>
<td><asp:Button runat="server" ID="btnIncrease2" Text="+>>"/><br /><br /><asp:Button runat="server" ID="btnDecrease2" Text="<<-"/> </td>
<td><asp:ListBox runat="server" ID="lbDept4" SelectionMode="Multiple" Rows="16" Width="70">
</asp:ListBox></td>
</tr>
</table>
</contenttemplate>
</asp:UpdatePanel>
</asp:Panel>
</asp:Panel>
<ajaxToolkit:ModalPopupExtender ID="ModalPopupExtender" runat="server"
TargetControlID="ibtnTarget"
PopupControlID="Panel3"
BackgroundCssClass="modalBackground"
OnOkScript="onOk()"
CancelControlID="CancelButton"
PopupDragHandleControlID="Panel4" />
</edititemtemplate>
</asp:TemplateField>
</columns>
</asp:GridView>
</div>

62,074

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术交流专区
javascript云原生 企业社区
社区管理员
  • ASP.NET
  • .Net开发者社区
  • R小R
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

.NET 社区是一个围绕开源 .NET 的开放、热情、创新、包容的技术社区。社区致力于为广大 .NET 爱好者提供一个良好的知识共享、协同互助的 .NET 技术交流环境。我们尊重不同意见,支持健康理性的辩论和互动,反对歧视和攻击。

希望和大家一起共同营造一个活跃、友好的社区氛围。

试试用AI创作助手写篇文章吧