OleDbConnection con=new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; data source=data.mdb"); con.Open(); OleDbCommand dc=new OleDbCommand("select name from us where id=2", con); textBox1.Text=dc.ExecuteScalar().ToString();
OleDbConnection con=new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; data source=data.mdb"); con.Open(); OleDbCommand dc=new OleDbCommand("insert into us (name) values (11)", con); dc.ExecuteNonQuery(); con.Close();