I found the problem. It was up to the use of "
using" on
OleDbCommandBuilder. So I changed my code as follows
OleDbDataAdapter da = new OleDbDataAdapter(sql, (OleDbConnection) Cnn);
OleDbCommandBuilder cb = new OleDbCommandBuilder(da);
cb.QuotePrefix = "[";
cb.QuoteSuffix = "]";
da.InsertCommand = cb.GetInsertCommand();
da.DeleteCommand = cb.GetDeleteCommand();
da.UpdateCommand = cb.GetUpdateCommand();
return da;
and the property InserCommand of my
da object now is good, no more null!
Sincerely I dunno why