Re: How to get embedded OLE objects out

From: exponent (exponent_at_hotmail.com)
Date: 09/16/04


Date: 16 Sep 2004 19:55:19 +0200


There are several ways to store images in OLE Object fields. If you have used 'OLE Embedding', it is quite
possible/likely that you will save space by using a different approach. A firm answer depends on the type
(and compression) of the source files, and the particular 'OLE server' application that was used to 'embed'
the image in the database. We have seen overhead of close to 200 *times* the size of the original file
in particular circumstances.

The main alternatives are to work with images in the filesystem, or images in the database (as raw-binary/blob
data, which has little or no overhead compared with the filesystem).

Either way, you first need to get the OLE Embedded images out. MSDN contains information on extracting
a bitmap from OLE objects. Stephen Lebans provides an implementation that also offers the possibility
to re-compress the extracted bitmap to JPEG. Our own image control also has this capability.

Larry Linson's imaging samples contain a code solution to raw-binary/blob imaging (by extracting to temporary
file and loading into an Access Image control). Our image control can also be bound directly to binary
fields (requiring no code) and offers a range of useful extra capabilities, such as lossless jpeg rotation,
asynchronous decoding, EXIF info viewer, resampling etc.

Some additional info on OLE Embedding vs raw-binary/blob storage is available here:
http://www.ammara.com/articles/imagesaccess.html

Stephen and Larry's sites are available via our links page (see url in sig). If it is of interest our
own image control is also available here, along with information, samples and solutions on imaging in Access.

--
_______________________________________________________
http://www.ammara.com/   
Image Handling Components, Samples, Solutions and Info
DBPix 2.0 - lossless jpeg rotation, EXIF, asynchronous
"Aaron" <NONE> wrote:
>The database I am working with has lot's of graphic files embedded in the
>database as OLE objects.  Apparently this takes up LOTS of space.  I was
>thinking that if there was an easy way to extract the files to a folder, a
>link to the file might free up some space.  I have two questions pertaining
>to this:
>
>1.  Will be more space-effective to remove the files from the database and
>move them to a separate folder.
>2.  Does anybody have a tidbit of code that might help me get started with
>saving the object to a folder?
>
>Thanks in advance for your help,
>Aaron
>
>
>


Relevant Pages


Loading