need an example
-
-
hi i need an example how to work with datagrid in C# lets say i have table in SQL server that called Stock_ID and one of the collumn is Symbol how can i get the value of the Symbol from the datagrid lets say i awnt to display all Symbols thanks eyalso
.NET 1.1: MSDN - DataGrid[^] .NET 2.0: MSDN2 - DataGridView[^] ___________________________________ Tozzi is right: Gaia is getting rid of us. My Blog [ITA]
-
hi i need an example how to work with datagrid in C# lets say i have table in SQL server that called Stock_ID and one of the collumn is Symbol how can i get the value of the Symbol from the datagrid lets say i awnt to display all Symbols thanks eyalso
protected void get_Click(object sender, EventArgs e) { SqlConnection conn = new SqlConnection("server=lzq;database=pubs;uid=sa;pwd="); SqlDataAdapter da = new SqlDataAdapter("select * from lzq", conn); DataSet ds = new DataSet(); da.Fill(ds, "t1"); datagrid1.DataSource = ds.Tables["t1"].DefaultView; datagrid1.DataBind(); }