I have given an example for barcodes. It can some other images related to the numbers. I want to store images as in MS access through VB code instead of inserting them manually.
Main Topics
Browse All TopicsDear Experts
I am having problems to save barcode bmp files as OLE object in MS Access OLE Object Field
I have a folder containing barcode images numbered sequentially e.g.
110001.bmp, 110002.bmp, 110003.bmp etc
and I have the same numbers in a table in MS Access of Office 2000 in field named 'bcn'
I have another field (OLE object) type named 'bcimages'
I want a solution to save the barcodes in OLE embeded format in MS access through a VB code
for each of the corresponding numbers
I referred to the microsoft URL http://support.microsoft.c
It suggested using datacontrol. But it not accepting MS Access 2000 file
giving a message " unrecognized database format"
I tried to use ADODB recordset through VB6 code, but I am not finding a way to
bind the OLE field in MS access to OLE active X object in Visual basic 6 through the code
I am writing the code which obviously not working.
Private Sub Command1_Click()
Call fnconn
rsbc.Open "select * from tblbcn", cnacc, 1, 3
rsbc.MoveFirst
While Not rsbc.EOF
Me.Text1.Text = rsbc("bcn")
OLE1.CreateEmbed "c:\barcodetest\" & rsbc("bcn") & ".bmp"
'??? code to bind bcimage in the recordset i.e. rsbc("bcimage")
rsbc.Update
rsbc.MoveNext
Wend
rsbc.Close
Set rsbc = Nothing
cnacc.Close
Set cnacc = Nothing
MsgBox ("over")
End Sub
I am seeking help from experts to complete the code or
any other method that helps to solve my problem
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
I see ...
First: It is most definitely NOT a good idea to store images in an Access database, which was one of the main reasons for asking this question. Access doesn't handle images well, and storing them can cause (a) significant bloat and (b) corruption. You're generally much better off storing images in a folder, and storing the Path to that folder in Access.
Why it's not a good idea:
http://support.microsoft.c
That said, if you must store them, you need to use GetChunk and AppendChunk:
http://msdn.microsoft.com/
Dear
Create 2 field in your Access database
1.SizeField Number
2.Photo Ole Object
....................
when will you going to save your data then
save your all data exept [SizeField,Photo]
when your data saved in database
strFileName 'STORE FILE LOCATION
If strFileName <> vbNullString Then
rs.Open "SELECT SIZEFEILD,PHOTO FROM TABLE WHERE ID='" & PrimKey & "'", CNN, adOpenKeyset, adLockOptimistic
GetPhoto strFileName, rs, "SizeFeild", "Photo"
rs.Update
rs.Close
En
........................
when you want to get image from record set
rs.open "SELECT * FROM TABLENAME",CONNECTION
FillPhoto Rec, "Photo", "SizeFeild", Image1
....................
Business Accounts
Answer for Membership
by: LSMConsultingPosted on 2009-08-24 at 07:05:33ID: 25168399
Can I ask why you're storing images of your barcodes? What do you need to do with them?
YOu can use barcode Fonts to display them on Forms and Reports, if that's what you're after.