You don't have to use a datatable and dataadapter but you
do need more than just the OleDbConnection object. You
could try using the OleDbCommand object instead.
// -- Start Code Example
string ConnectionString
= "Provider=Microsoft.Jet ..etc..";
OleDbConnection conn = new OleDbConnection
(ConnectionString);
OleDbCommand comm = new OleDbCommand();
comm.CommandText = "INSERT INTO ..etc..";
comm.Connection = conn;
conn.Open();
comm.ExecuteNonQuery();
conn.Close();
// -- End Code Example
HTH
Sam
-----Original Message-----
Hello,
i have a project where every time i want to add or
updatesomething in the DB i use the datatable and dataadpter
and i build an insert sql command or an update sql
command to the dataadapter and then use the update.
i want to know if i can execute the command i make
directly through the connection object (oledb) and not
create the datatable and dataadapter
thank u
.