You might want to simplify it by not using the OleDbDataAdapter, but use an OleDbCommand directly.
string strConnection = "Provider=Microsoft.Jet.OLEDB.4.0;" + "Data Source=datacapt.mdb";
OleDbConnection conn = new OleDbConnection(strConnection);
conn.Open();
string strCommand = "INSERT INTO compdata(ID,CompanyName,ContactName) Values ('" + txID.Text + "','" + txtName.Text + "','" + txtcontact.Text + "')";
OleDbCommand comm = new OleDbCommand(strCommand, conn);
int t1 = command.ExecuteNonQuery();
conn.Close();
if (t1 > 0)
{
MessageBox.Show("added successfully!");
}