header photo

Read/Write Images to MS Access Database Table Using C# Winform

 Lets create a C# winform application that Reads images and text from an MS Access Database Table and Writes to it too!

NOTE To All Following my Face Recognition Series: This is a detailed tutorial on how Oledb classes are used in my tutorials to connect our C# winform to MS Access for storing and reading images from it. Trust me the concept wasn't that simple to explain in a video or two while implementing Face Recognition. So i had to make this full tutorial especially. i suggest you watch it before or while implementing Training Set Manager or Face Recognizer.


its not as boring as you might think, look, I even ANIMATED Oledb(sorta) so that it'll go easier on the brain. So click the play button you beautiful you!

STEP 2: ok its time to see the demo of the final output, explaining what functionality we'll be coding to make this application.

STEP 3: The project design and user controls (buttons form and picturebox) are explained in this video.

DOWNLOAD SOLUTION FILE: This is the VS2010 Solution File with the MS database file (located in the bin folder) and all the UI controls plus their click-events as explained earlier, are ready BUT empty - all you need to do is open the solution file, follow along with the tutorial and add in the code as instructed.

STEP 4: Okie dokie! Now that we have the application ready, with buttons and everything in place, lets code behind them. we'll start with looking at our "Coding To Do" list and then go on to declare the global variables needed, then we'll connect to the database so you MUST WATCH this video - yes, you are under my control, you can hear only my voice, and you're feeling SLEEPY~~~ or maybe that's just coz of my boring tutorial. :P

STEP 5: Alright! you survived all that?! i salute you! now lets finally add the images to database


STEP 6: now that we've added some images to the database, lets READ them and show them in the picturebox.

STEP 7: Wanna learn How to delete a record from MS Access table using OLEDB classes in C# Winform? hmmm? did i hear you say a "No"??? Don't make me force you.just click that play button. NOW!!! :P

 AAAAAAnd with that this tutorial comes to an end. PHEW! see, didn't feel like you were forced to watch, right? RIGHT??? hmmmmm???? LOL


Go Back