Wrox Programmer Forums
Access VBA Discuss using VBA for Access programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old October 11th, 2004, 01:17 PM
Registered User
Join Date: Aug 2004
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default OLE Object Type?


I am having trouble returning a bitmap image from a field stored in my database. The field's Tpye is a OLE Object and it holds a Bitmap Image, Im trying to display the image on a Form after it has been retrieved using the Dlookup funtion I've tried to assign a variable (rtImage)with various object types with no joy. I keep getting a Tpye mismatch error message when I try to link the field.

for instance:

Dim rtImage As Long

rtImage = DLookup("Product_Name", "[Main _ products]", "Product_Image =" & Me.OpenArgs)

can Anyone help?

Thanks John

Old October 20th, 2004, 02:16 PM
Friend of Wrox
Join Date: Mar 2004
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts

I don't have all the info, but perhaps the bound column in your look up is the wrong one. Bind it to the other or another column perhaps? This is the source of many type mismatch errors with custom look ups (heck, even with wizard generated look ups coupled with custom code.)


Similar Threads
Thread Thread Starter Forum Replies Last Post
The OLE object is empty leegweaver Access VBA 4 June 20th, 2008 07:59 AM
embeding an OLE object ricespn Beginning VB 6 0 August 17th, 2007 12:47 AM
ole object insertion vinodkselpy Crystal Reports 0 March 1st, 2007 07:31 AM
Saving OLE Object to FIle being_oblivious Access VBA 0 August 2nd, 2005 07:34 PM
OLE object in ASP MDrumm BOOK: Beginning ASP 3.0 3 June 18th, 2005 10:48 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.