Acessing embedded images in VB 
Author Message
 Acessing embedded images in VB
I need to access embedded images (both bitmaps and jpegs) from fields in an
access recordset. I am using Jet and VB6.

I can access the data from the field using GetChunk, but cannot figure out
what to do with the data to pass it to an image control. the image control
Picture property wants a file name. I have tried writing the data to a file
and using that file, but have gotten file format errors. I have also thought
about copying the data to the clipboard so that I can paste into the
control, but cannot figure out how to do that - I get errors about an object
being required when I call Clipboard.SetData.

I assume I am not the first person to try doing this. Has anyone had any
experience with something like this and can tell me what I am missing here?

Regards,
David Fenton



Tue, 19 Mar 2002 03:00:00 GMT  
 Acessing embedded images in VB
Once you use the GetChunk to create a physical file (usually a tmp file) you
just use LoadPicture([path to temp file])

Demo/source code at:

http://www.smithvoice.com/appendin.htm

-Smith

Quote:

>I need to access embedded images (both bitmaps and jpegs) from fields in an
>access recordset. I am using Jet and VB6.

>I can access the data from the field using GetChunk, but cannot figure out
>what to do with the data to pass it to an image control. the image control
>Picture property wants a file name. I have tried writing the data to a file
>and using that file, but have gotten file format errors. I have also
thought
>about copying the data to the clipboard so that I can paste into the
>control, but cannot figure out how to do that - I get errors about an
object
>being required when I call Clipboard.SetData.

>I assume I am not the first person to try doing this. Has anyone had any
>experience with something like this and can tell me what I am missing here?

>Regards,
>David Fenton



Tue, 19 Mar 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Help - extracting image path from embedded image field

2. OL2K: problems embedding images using VB and Outlook Objects

3. Embedded OLE image object from Acces 2000 to VB 6.0

4. Passing parameters from embedded VB to embedded VC++

5. acessing outlook from vb

6. Acessing BIOS settings w/VB

7. Limitations on VB acessing C++ DLLs?

8. Acessing Acitivex-dll in VB

9. Acessing Acitivex-dll in VB

10. Powerpoint/Vba -Embedding Images In Toggle Buttons?

11. Embedding multiple images into fields

12. Embedding images into Outlook 2000

 

 
Powered by phpBB® Forum Software