Click here to Skip to main content
15,905,232 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Good day, i have a modalpopupextender which doesnt appear on the center, any idea how to solve this? Here is my code




<pre lang="xml"><asp:Panel ID="pnlSelect" runat ="server" Enabled ="true"
    CssClass ="modalPopup"
    style="position:fixed; z-index:10; top: 193px; left: 10px; width: 192px; height: 220px; bottom: 242px;" >
<div id="PopupHolder_CalendarAdmin" class="pnlheader" style="cursor:move; width:191px; height:20px; font-size:small; font-weight:bold; color:#FFFFFF; text-align:center;">
    <asp:Label ID="lblSelect" runat="server" Text="Select" />

    <div style="width: 181px">
    <br />
        <table >
        <tr>
        <td class="style3">
            <asp:Button ID="btnIsCurrent" runat="server" Text="IsCurrent" />
            </td>
        <td class="style3">
            <asp:Button ID="btnSuspend" runat="server" Text="Suspend" />
            </td>
        </tr>
        </table>
    </div>

    <asp:Button ID="btnHidden1" runat ="server" Text ="hidden" style="display:none;" />
    <aj:ModalPopupExtender ID ="mpSelect" runat ="server" TargetControlID ="btnHidden1"
        PopupControlID ="pnlSelect" DropShadow ="true" BackgroundCssClass ="modalBackground"
        PopupDragHandleControlID="PopupHolder_CalendarAdmin" />
        </div>
</asp:Panel>
Posted
Comments
RelicV 13-Dec-13 4:07am    
Hi Goenitz, pls remove the panel style and add this instead
style="width: 192px; height: 220px;"

Let us know the progress
Goenitz 13-Dec-13 4:29am    
Thank you for your kind answer :)
RelicV 13-Dec-13 7:31am    
Im glad it helped you. have fun with coding. :)

Thank you for your answer :), ive done it myself ^^
 
Share this answer
 
Comments
King Fisher 13-Dec-13 4:37am    
add your solution here.it may help someone.
Goenitz 15-Dec-13 19:58pm    
It just had something to do with x and y and the position of the div in the GUI :)
C#
<asp:ModalPopupExtender ID="ModalPopupExtender1" runat="server" PopupControlID="Panel1" TargetControlID="search" BackgroundCssClass="modalBackground">
 

   </asp:ModalPopupExtender>
 
    <asp:Panel ID="Panel1" runat="server" BackColor="#ED95CC" Height="200px" Width="400px" style="display:none">

//you can create a table inside the panel for align the recodrs
  </asp:Panel>
 
Share this answer
 
v3

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900