Solved

Reading/writing TBitmaps to an MS Access table

Posted on 2002-04-09
4
131 Views
Last Modified: 2010-04-04
I need to store the contents of a TImage to my MS Access table. I need one procedure for loading data and one for saving data. The only type Access seems to have for binary data is "OLE Object". I don't have the slightest clue on how to do this.

Please help!


regards,
Johan Sageryd
0
Comment
Question by:sageryd
  • 2
  • 2
4 Comments
 
LVL 27

Accepted Solution

by:
kretzschmar earned 200 total points
ID: 6927645
yep,

access stores blobs with an ole-server information prefix.

if there is no need to access the content within the access-frontend, then you should be able to store your images simple with

tblobfield(dataset.fieldbyname('fieldname')).loadfromfile('filename');  //or loadfromstream

savetofile/savetostream for the other direction

if your images are from different graphicformat, you need also a typefield in your table

meikl ;-)
0
 
LVL 1

Author Comment

by:sageryd
ID: 6927656
Just discovered that on my own :)  Thanks anyway Meikl!!
0
 
LVL 27

Expert Comment

by:kretzschmar
ID: 6927668
well, glad you got it works,
thanks for the points :-)
0
 
LVL 1

Author Comment

by:sageryd
ID: 6927676
;)

Thanks again


I'm making a program for teaching japanese. I recon I might be able to sell it to my school. :)
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

912 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

24 Experts available now in Live!

Get 1:1 Help Now