Please, read my comment to the question.
I see at least 2 reasons of above behaviour:
1) Connection string is incomplete!
Should be:
cons = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\myFolder\myAccessFile.accdb; Persist Security Info=False;"
2) Update statement could be wrong!
a) If
InitialBatchID
and
GLID number
are numeric fields, you should remove
'
arounding values.
b) If field name contains space between words, you should add
[]
bracket around it:
[GLID number]
instead of
'GLID number'
Finally:
If executable is in the same folder, you need to move it into another folder.
OriginalGriff is right. You should use parametrized queries.