In this tutorial I will explain to you on how to connect to an Access database and allow you to Add/Update/Delete a record.
To fully understand these tutorials please download the source code How to Add/Update/Delete Record using MS Access Database.
This source code is part of the Hotel Reservation System that I am currently working.
At the end of this tutorial you will learn the basic of database programming. I would like, however, to emphasize especially for beginners that one way to learn programming is to know how to debug a program and devote some of your time to reading. Don't be frightened on how short or long an article should be. The important is at the end of the tutorial you will learn something NEW! If you already know the topic, then don’t bother to study this again.
Table of Contents 1. Introduction 2. Let’s get started 3. Database Connection 4. Add and Update a Record 5. Delete a Record 6. Final Thoughts
Introduction
Before I started learning VB.NET one of the topic that I search for in the internet is on how to connect to the database and make some changes to the table. Although there’s a lot of results, but I cannot find one that suit to my needs. Most of the tutorial is using drag and drop features of vb.net editor. Well, this is okay in most cases but what if you’d like to manipulate the data by code? So, I created this tutorial so that beginner programmer will learn from this.
Let’s get started
It is very important that you use your common sense to understand the logic of database programming. There’s a lot of features built-in to Visual Basic Editor that most programmer especially beginner who overlook it. One of the favorite tools I usually used is the DEBUGGER. If you only knew how important a debugger is, then you do not even need to study this tutorial. Why? Because you can jump right away to the source code and start firing the F8 command from your