Tabcontainer问题与呈现选项卡条带

时间:2015-02-07 11:46:09

标签: c# asp.net ajaxcontroltoolkit tabcontainer

enter code![as you can see here the tabs are half eaten!][1] here
  

您好,我有显示标签条带的问题我不知道它有什么问题。任何人都可以帮忙吗?当我运行这个选项卡没有完全显示我有三个选项卡,我尝试使用不同的浏览器,但问题仍然存在。

下面的

代码示例:

<asp:TabContainer ID="TabContainer1" runat="server" ActiveTabIndex="0" BackColor="#62A5C8" BorderStyle="none" ForeColor="#ffffff" Height="450px" server="" Style="  background-color:#012F54; margin-top: 0px;" Width="100%" ScrollBars="Both" Font-Size="Medium"
ToolTip="Move between tabs to fill-in all information">


  <asp:TabPanel runat="server" HeaderText="Student Information" ID="TabPanel1">
    <ContentTemplate>
      <asp:UpdatePanel ID="updatePanel1" runat="server">
        <ContentTemplate>
          <table class="auto-style15">
            <tr>
              <td class="auto-style27">
                <br />
                <span class="auto-style117">First Name:<br /> </span>
              </td>
              <td class="auto-style21">
                <br />
                <strong>&nbsp;
                            <asp:TextBox ID="TextBox1" runat="server" BorderColor="Black" BorderStyle="Solid" Height="23px" Width="198px" CssClass="auto-style116"></asp:TextBox>
                            </strong>
              </td>
              <td>&nbsp;</td>
            </tr>
            <tr>
              <td class="auto-style28">&nbsp;</td>
              <td class="auto-style21">&nbsp;</td>
              <td>&nbsp;</td>
            </tr>
            <tr>
              <td class="auto-style117">Last Name:</td>
              <td class="auto-style24"><strong>
                            &nbsp;
                            <asp:TextBox ID="TextBox2" runat="server" BorderStyle="Solid" Height="21px" Width="198px" BorderColor="Black" CssClass="auto-style116"></asp:TextBox>
                            </strong>
              </td>
              <td class="auto-style25"></td>
            </tr>
            <tr>
              <td class="auto-style17"></td>
              <td class="auto-style20"></td>
              <td class="auto-style18"></td>
            </tr>
            <tr>
              <td class="auto-style27" style="font-size: small; color: #043d5d">Student ID:</td>
              <td class="auto-style21"><strong>
                            &nbsp;
                            <asp:TextBox ID="TextBox3" runat="server" BorderStyle="Solid" Height="23px" Width="198px" BorderColor="Black" CssClass="auto-style116"></asp:TextBox>
                            </strong>
              </td>
              <td>&nbsp;</td>
            </tr>
            <tr>
              <td class="auto-style28">&nbsp;</td>
              <td class="auto-style21">&nbsp;</td>
              <td>&nbsp;</td>
            </tr>
            <tr>
              <td class="auto-style27" style="font-size: small; color: #043d5d">Department:</td>
              <td class="auto-style21"><strong>
                            <asp:DropDownList ID="DropDownList1" runat="server" Height="27px" Width="295px" style="margin-left:7px;">
                                            <asp:ListItem>Cardiac Technology</asp:ListItem>
                                            <asp:ListItem>Clinical Laboratory Sciences</asp:ListItem>
                                           
                                        </asp:DropDownList>
                            </strong>
              </td>
              <td>&nbsp;</td>
            </tr>
            <tr>
              <td class="auto-style28">&nbsp;</td>
              <td class="auto-style21">&nbsp;</td>
              <td>&nbsp;</td>
            </tr>
            <tr>
              <td class="auto-style28">&nbsp;</td>
              <td class="auto-style21">&nbsp;</td>
            </tr>
            <tr>
              <td class="auto-style28">&nbsp;</td>
              <td class="auto-style21">&nbsp;</td>
            </tr>
            <tr>
              <td class="auto-style28">&nbsp;</td>
              <td class="auto-style21">&nbsp;</td>

              <td>
                <asp:Button ID="Button1" runat="server" BackColor="#4DA3B0" BorderColor="#4DA3B0" Font-Bold="False" Font-Size="12pt" ForeColor="White" Height="36px" style="margin-left:10px;" Text="Next ►" Width="166px" />
              </td>
            </tr>
          </table>
        </ContentTemplate>
      </asp:UpdatePanel>
    </ContentTemplate>
  </asp:TabPanel>

  <asp:TabPanel ID="TabPanel2" runat="server" HeaderText="Graduate Form">
    <ContentTemplate>
**

1 个答案:

答案 0 :(得分:0)

嗨兄弟使用下面的代码 首先在页面顶部添加引用

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

然后使用下面的代码

<asp:ScriptManager runat="server" ID="sc">
        </asp:ScriptManager>
        <asp:TabContainer ID="TabContainer1" runat="server" ActiveTabIndex="0" BackColor="#62A5C8"
            BorderStyle="none" ForeColor="#ffffff" Height="450px" server="" Style="background-color: #012F54;
            margin-top: 0px;" Width="100%" ScrollBars="Both" Font-Size="Medium" ToolTip="Move between tabs to fill-in all information">
            <asp:TabPanel runat="server" HeaderText="Student Information" ID="TabPanel1">
                <ContentTemplate>
                    <table class="auto-style15">
                        <tr>
                            <td class="auto-style27">
                                <br />
                                <span class="auto-style117">First Name:<br />
                                </span>
                            </td>
                            <td class="auto-style21">
                                <br />
                                <strong>&nbsp;
                                    <asp:TextBox ID="TextBox1" runat="server" BorderColor="Black" BorderStyle="Solid"
                                        Height="23px" Width="198px" CssClass="auto-style116"></asp:TextBox>
                                </strong>
                            </td>
                            <td>
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style28">
                                &nbsp;
                            </td>
                            <td class="auto-style21">
                                &nbsp;
                            </td>
                            <td>
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style117">
                                Last Name:
                            </td>
                            <td class="auto-style24">
                                <strong>&nbsp;
                                    <asp:TextBox ID="TextBox2" runat="server" BorderStyle="Solid" Height="21px" Width="198px"
                                        BorderColor="Black" CssClass="auto-style116"></asp:TextBox>
                                </strong>
                            </td>
                            <td class="auto-style25">
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style17">
                            </td>
                            <td class="auto-style20">
                            </td>
                            <td class="auto-style18">
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style27" style="font-size: small; color: #043d5d">
                                Student ID:
                            </td>
                            <td class="auto-style21">
                                <strong>&nbsp;
                                    <asp:TextBox ID="TextBox3" runat="server" BorderStyle="Solid" Height="23px" Width="198px"
                                        BorderColor="Black" CssClass="auto-style116"></asp:TextBox>
                                </strong>
                            </td>
                            <td>
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style28">
                                &nbsp;
                            </td>
                            <td class="auto-style21">
                                &nbsp;
                            </td>
                            <td>
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style27" style="font-size: small; color: #043d5d">
                                Department:
                            </td>
                            <td class="auto-style21">
                                <strong>
                                    <asp:DropDownList ID="DropDownList1" runat="server" Height="27px" Width="295px" Style="margin-left: 7px;">
                                        <asp:ListItem>Cardiac Technology</asp:ListItem>
                                        <asp:ListItem>Clinical Laboratory Sciences</asp:ListItem>
                                    </asp:DropDownList>
                                </strong>
                            </td>
                            <td>
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style28">
                                &nbsp;
                            </td>
                            <td class="auto-style21">
                                &nbsp;
                            </td>
                            <td>
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style28">
                                &nbsp;
                            </td>
                            <td class="auto-style21">
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style28">
                                &nbsp;
                            </td>
                            <td class="auto-style21">
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td class="auto-style28">
                                &nbsp;
                            </td>
                            <td class="auto-style21">
                                &nbsp;
                            </td>
                            <td>
                                <asp:Button ID="Button1" runat="server" BackColor="#4DA3B0" BorderColor="#4DA3B0"
                                    Font-Bold="False" Font-Size="12pt" ForeColor="White" Height="36px" Style="margin-left: 10px;"
                                    Text="Next ►" Width="166px" />
                            </td>
                        </tr>
                    </table>
                </ContentTemplate>
            </asp:TabPanel>
            <asp:TabPanel ID="TabPanel2" runat="server" HeaderText="Graduate Form">
                <ContentTemplate>
                </ContentTemplate>
            </asp:TabPanel>
        </asp:TabContainer>