Insert a picture in mdb file and then extract it

Posted on 2005-04-16
Last Modified: 2010-05-18
My application uses an access db as its data source repository and handling the data is all right, but...
I want to have an option to insert a picture (e.g. jpeg file) into the database and then extract it and I've got no idea how to it.
I'm using different structures to hold extracted data, such as datasets, arraylists, and etc.

Would appreciate you suggestions and code snippets in particular.

Question by:Yurich
    LVL 22

    Accepted Solution

    LVL 8

    Assisted Solution

    LVL 21

    Author Comment

    hello guys and thanks for your answers.
    i'll have a look at the links next couple of days.

    LVL 21

    Author Comment

    thanks guys,
    all links are useful, yet using vinh's way i had an exception saying that I've got no encoder when I'm trying to save image into the memory stream...

    MemoryStream ms = new MemoryStream();
    pictureBox1.Image.Save( ms, pictureBox1.Image.RawFormat );
    LVL 21

    Author Comment

    ... but I can use:

    pictureBox1.Image.Save( ms, System.Drawing.Imaging.ImageFormat.Jpeg );

    and it'll work just fine

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    Join & Write a Comment

    Extention Methods in C# 3.0 by Ivo Stoykov C# 3.0 offers extension methods. They allow extending existing classes without changing the class's source code or relying on inheritance. These are static methods invoked as instance method. This…
    Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
    Hi everyone! This is Experts Exchange customer support.  This quick video will show you how to change your primary email address.  If you have any questions, then please Write a Comment below!
    Here's a very brief overview of the methods PRTG Network Monitor ( offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

    732 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now