.NET will write the code for you.

You need to drop a data connector on to the form and then set its properties. There is a wizard to help with it. It will then create the code. Look at the code, and you will see how it is done. You can cut and paste it to use elsewhere, and just change the things you need, like the DB location etc.

The Help documentation and walkthroughs are aimed mainly at SQL Server (I guess MS is pushing it) but it's pretty much the same for any connection.

As I understand it (I'm still learning this), it is better to avoid ADO now, and use the recommended .net method as it is faster and more robust, and the data moves as XML, so it can travel more easily over the Internet, through firewalls that block binary traffic etc.

I'm writing a general purpose Access connector that I can call with just a database location and table name, but it's a long way from finished and full of bugs. Happy to send you a copy when it's done, unless you get there first, in which case I'd be interested to see your code!