You are on page 1of 1

if (!

IsPostBack)
{
Response.Write(System.DateTime.Now);
DataTable dt = new DataTable();
SqlDataAdapter adpt = new SqlDataAdapter("Select * from Record", con
);
adpt.Fill(dt);
DropDownList1.Items.Add("--SELECT--");
foreach (DataRow dr in dt.Rows)
{
DropDownList1.Items.Add(dr[1].ToString());
}
}

You might also like