<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:Label ID="Label1" runat="server" Font-Bold="True" Font-Size="X-Large"
Font-Underline="True" ForeColor="Red" Text="PRODUCT INFORMATION"></asp:Label>
</div>
<asp:Label ID="Label2" runat="server" Text="Category"></asp:Label>
<asp:DropDownList ID="DropDownList1" runat="server"
onselectedindexchanged="DropDownList1_SelectedIndexChanged"
AutoPostBack="True">
</asp:DropDownList>
<br><br />
<asp:Label ID="Label3" runat="server" Text="Subcategory"></asp:Label>
<asp:DropDownList ID="DropDownList2" runat="server"
onselectedindexchanged="DropDownList2_SelectedIndexChanged"
AutoPostBack="True">
</asp:DropDownList>
<br><br>
<asp:Label ID="Label4" runat="server" Text="Status"></asp:Label>
<asp:DropDownList ID="DropDownList3" runat="server"
onselectedindexchanged="DropDownList3_SelectedIndexChanged"
AutoPostBack="True">
</asp:DropDownList>
<br />
<br />
<asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Search"
style="height: 26px" />
<br />
<asp:GridView ID="GridView1" runat="server"
onselectedindexchanged="GridView1_SelectedIndexChanged" BackColor="White"
BorderColor="#3333FF" AllowPaging="True">
</asp:GridView>
</form>
</body>
</html>
..........................................................................................
protected void Button1_Click(object sender, EventArgs e)
{
string select2 = "select * from item";
adp = new SqlDataAdapter(select2, con);
DataSet ds3 = new DataSet();
adp.Fill(ds3);
GridView1.DataSource = ds3;
GridView1.DataBind();
}
Abhisekjani, if this helps please login to Mark As Answer. | Alert Moderator