My source page code as follows
<ajaxToolkit:TabContainer ID="TabContainer1" runat="server" ActiveTabIndex="0">
<ajaxToolkit:TabPanel ID ="tbfaculty" runat ="server">
<HeaderTemplate>
Faculty
</HeaderTemplate>
<ContentTemplate>
<asp:Panel id="pnlfac" runat="server" backcolor="White" bordercolor ="Black" borderstyle="Solid" borderwidth="1px" height="144px">
<asp:GridView id="gvfaculty" runat="server" backcolor="LightGoldenrodYellow" BorderColor="Tan" width="91px" autogeneratecolumns = "False" ForeColor="Black">
<FooterStyle BackColor="Tan" />
<HeaderStyle BackColor="Tan" Font-Bold="True" />
<PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" HorizontalAlign="Center" />
<SelectedRowStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite" />
<Columns>
<asp:BoundField DataField="Faculty Name" HeaderText="Faculty Name" />
<asp:TemplateField HeaderText="Does the Faculty come well prepared for his subject">
<ItemTemplate>
<asp:DropDownList ID="DropDownList1" runat="server" AppendDataBoundItems="true">
<asp:ListItem Value="-1">--Select Rating --</asp:ListItem>
</asp:DropDownList>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Is he loud and clear in his speech">
<ItemTemplate>
<asp:DropDownList ID="DropDownList1" runat="server" AppendDataBoundItems="true">
<asp:ListItem Value="-1">--Select Rating --</asp:ListItem>
</asp:DropDownList>
</ItemTemplate>
</asp:TemplateField>
in run mode in tab container as follows
Faculty
When i click the faculty in tab container i want to show the gridview.
for display the gridview content in tab container i written a code as follows
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
try
{
Facultybindgrid();
}
catch
{
}
}
}
private void Facultybindgrid()
{
DataTable dt = new DataTable();
dt.Rows.Add("CPG");
dt.Rows.Add("BSR");
gvfaculty.DataSource = dt;
gvfaculty.DataBind();
gvfaculty.Visible = true;
}
but when i run and click the faculty in tab container the gridview is not displaying.
please help me.from my above code what is the mistake i made.
regards
Jegan B