Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3433234
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T07:32:56+00:00 2026-05-18T07:32:56+00:00

I got a table with 2 nested tables inside that display my two repeaters.

  • 0

I got a table with 2 nested tables inside that display my two repeaters. My repeaters display Home and office addresses respectively. The problem is that whenever I add a new record in one repeater, the other repeater table’s display gets messed up. Like if I add a record in rpt1 , then table for rpt1 moves up and table for rpt2 goes down..ie the headers do not display in one single line . They move up and down when records are added or deleted. WHat I want is these headers to be fixed so if I add new records or delete records, the headings of both repeaters display on the same line…How do I fix this ? Hope its not confusing.

<table width="100%" cellpadding="0" cellspacing="0">
         <tr>
            <td width="50%">
              <asp:Panel ID="pnlAddAddress" runat="server">
                <asp:Repeater ID="rpt1" OnItemCommand="rpt1_ItemCommand" runat="server" OnItemDataBound="rpt1_OnItemDataBound">

                 <HeaderTemplate>                              
                   <table width="99%" border="0" cellpadding="0" cellspacing="0">
                     <tr>
                 <td colspan="5" class="linegrey">
                       </td>
                     </tr>
                     <tr class="lgrey">
                       <td>
                           Address1
                      </td>

                       <td>
                           City
                       </td>
                        <td>
                          State
                       </td>

                       <td>
                         IsDefault
                       </td>
                       <td>
                         Actions
                      </td>
                   </tr>
                   <tr>
                     <td colspan="5" class="dots">
                   </tr>
             </HeaderTemplate>
             <ItemTemplate>
                  <tr>
                    <td>

                      <asp:LinkButton ID="lnkAddressB" runat="server" Text='<%# Eval("Address1")%>' CommandName="DisplayAddressB" CommandArgument='<%#Eval("AddID") %>' CausesValidation=false></asp:LinkButton>

                    </td>

                     <td>
                       <%# Eval("City")%>

                    </td>
                    <td>
                       <%# Eval("State")%>
                    </td>

                    <td>

                     <%-- Visible='<%# Eval("IsDefault")%>'--%>

                      <asp:LinkButton ID="lnkDefaultB" Text="Set as Default" CommandName="SetDefaultB" runat="server" CommandArgument='<%# Eval("AddID") + "," + Eval("IsB") %>'
                      CausesValidation="false" Visible='<%# Eval("IsDefault")%>'></asp:LinkButton>
                      <asp:Label ID="labelDefaultB" Text="Yes" runat="server" Visible='<%# Eval("IsDefault")%>'></asp:Label>

                    </td>
                    <td>
                     <asp:ImageButton ID="lnkAdd" CommandArgument='<%#Eval("AddID") %>'
                      CausesValidation="false" CommandName="Edit" runat="server" ImageUrl="~/images/Edit.gif" Width="14" Height="14" ToolTip="Edit"></asp:ImageButton>
                      &nbsp;  
                      <asp:ImageButton ID="lnkDel" Text="Delete" CommandArgument='<%#Eval("AddID") %>'
                      CausesValidation="false" CommandName="Delete" runat="server" ImageUrl="~/images/Delete.gif" Width="14" Height="14" ToolTip="Delete"></asp:ImageButton>
                    </td>
                  </tr>
                </ItemTemplate>
                <FooterTemplate>
                </table>
                </FooterTemplate>
              </asp:Repeater>
            </asp:Panel>
           </td>
           <td>
             <asp:Panel ID="pnlSping" runat="server">
                <asp:Repeater ID="rpt12" OnItemCommand="rpt12_ItemCommand" runat="server" OnItemDataBound="rptSpping_OnItemDataBound">
                     <HeaderTemplate>
                         <table width="100%" border="0" cellpadding="0" cellspacing="0">
                             <tr>
                               <td colspan="5" class="linegrey">
                               </td>
                              </tr>
                              <tr class="lgrey">
                                 <td>
                                   Address1
                                 </td>
                                 <td>
                                   City
                                  </td>
                                  <td>
                                   State
                                   </td>
                                   <td>
                                    IsDefault
                                    </td>
                                    <td>
                                     Actions
                                     </td>
                                 </tr>
                                 <tr>
                                   <td colspan="5" class="dots">
                                  </tr>
                         </HeaderTemplate>
                         <ItemTemplate>
                                  <tr>
                                    <td>
                                       <asp:LinkButton ID="lnkAddressS" runat="server" Text='<%# Eval("Address1")%>' CommandArgument='<%#Eval("AddID") %>' CommandName="DisplayAddressS" CausesValidation="false"></asp:LinkButton>
                                     </td>

                                     <td>
                                     <%# Eval("City")%>
                                     </td>
                                     <td>
                                      <%# Eval("State")%>
                                      </td>
                                      <td>
                                        <asp:LinkButton ID="lnkDefaultS" Text="Set as Default" CommandName="SetDefaultS" runat="server" Visible=true CommandArgument='<%# Eval("AddID") + "," + Eval("IsS") %>'
                                        CausesValidation="false"></asp:LinkButton>
                                        <asp:Label ID="labelDefaultS" Text="Yes" runat="server" Visible=true></asp:Label>
                                       </td>
                                       <td>
                                        <asp:ImageButton ID="lnkAdd" Text="Edit" CommandArgument='<%#Eval("AddID") %>'
                                        CausesValidation="false" CommandName="Edit" runat="server" ImageUrl="~/images/Edit.gif" Width="14" Height="14" ToolTip="Edit"></asp:ImageButton>
                                        &nbsp; 
                                        <asp:ImageButton ID="lnkDel" Text="Delete" CommandArgument='<%#Eval("AddID") %>'
                                         CausesValidation="false" CommandName="Delete" runat="server" ImageUrl="~/images/Delete.gif" Width="14" Height="14" ToolTip="Delete"></asp:ImageButton>
                                        </td>
                                       </tr>
                             </ItemTemplate>
                              <FooterTemplate>
                                 </table>
                              </FooterTemplate>
                          </asp:Repeater>
                      </asp:Panel>
                  </td>
                 </tr>
          </table>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T07:32:57+00:00Added an answer on May 18, 2026 at 7:32 am

    Use css attribute valign and set its value to top like this <td width="50%" valign="top">.

    <table width="100%" cellpadding="0" cellspacing="0">
                <tr>
                    <td width="50%" valign="top">
                        <asp:Panel ID="pnlAddAddress" runat="server">
                            ......
                        </asp:Panel>
                    </td>
                    <td valign="top">
                        <asp:Panel ID="pnlSping" runat="server">
                            ......
                        </asp:Panel>
                    </td>
                </tr>
            </table>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got a table that is supposed to track days and costs for shipping
I have some nested tables that I want to hide/show upon a click on
I've got a table that helps me keep track of the delay times between
How do I linearize a nested table, which in itself also contains nested tables
I'm SO close, but so far. I've got two tables, one for publication details,
I got a table with a custom TableCellEditor (extending DefaultCellEditor) with a JFormattedTextField as
If I've got a table containing Field1 and Field2 can I generate a new
I've got a table of URLs and I don't want any duplicate URLs. How
I've got a table of hardware and a table of incidents. Each hardware has
I've got a table with a header, a row with input fields, rows with

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.