Solved

Reading/writing TBitmaps to an MS Access table

Posted on 2002-04-09
4
130 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
Comment Utility
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
Comment Utility
Just discovered that on my own :)  Thanks anyway Meikl!!
0
 
LVL 27

Expert Comment

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

Author Comment

by:sageryd
Comment Utility
;)

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

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

763 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

9 Experts available now in Live!

Get 1:1 Help Now