Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access
| Search | Today's Posts | Mark Forums Read
Access Discussion of Microsoft Access database design and programming. See also the forums for Access ASP and Access VBA.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access 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 November 21st, 2003, 04:35 AM
Authorized User
 
Join Date: Nov 2003
Location: Phoenix, AZ, USA.
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Default OLE object in table and Form control

I'm new to Access and have set up a table that includes a field for a picture as an OLE object. In the form I would like to use a Browse button that opens the standard windows File Open dialog to find the picture and then have it displayed on the Form as well as store the picture in the table - not just the path to it. Is this possible with Access, and if so, can someone direct me to where I might find information on how to do it? I tried searching the Microsoft site but didn't find anything.

Thanx much-

Bob

 
Old November 21st, 2003, 12:20 PM
sal sal is offline
Friend of Wrox
 
Join Date: Oct 2003
Location: Clarksville, TN, USA.
Posts: 702
Thanks: 0
Thanked 0 Times in 0 Posts
Default

just create the field as ole object. When you create a form, you can right click (or doubleclick I think) on the field where you want to store the object and the File dialog will automatically open for you. It is simple and easy to do.



Sal
 
Old November 21st, 2003, 01:05 PM
Authorized User
 
Join Date: Nov 2003
Location: Phoenix, AZ, USA.
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you - I got that far but double clicking doesn't work and if you right-click and select insert object, it brings up the "Create New/Insert Existing Object" dialog. This seems very cumbersome, especially for a user. For sake of user-friendlyness, is there a way to create a button to launch the File Open dialog so they can just search for the picture. It would be nice to have it restrict to a file type too - like jpeg.

 
Old November 21st, 2003, 01:24 PM
sal sal is offline
Friend of Wrox
 
Join Date: Oct 2003
Location: Clarksville, TN, USA.
Posts: 702
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You can use the file dialog in Access, but, it will not always work on all user machines depending on the version of Access and even SR level of Access. You can only get around that by using MOD, and that is a headache in itself.

Train your users on how to use the one supplied with Access, or create your own Active X control to do that (even harder).

Users, we kno them, we love them.



Sal




Similar Threads
Thread Thread Starter Forum Replies Last Post
embeding an OLE object ricespn Beginning VB 6 0 August 17th, 2007 12:47 AM
Extract OLE object from table to a folder ysiline Access VBA 0 May 9th, 2006 11:17 PM
How to control ole object programmatically uticket Crystal Reports 0 November 16th, 2004 12:35 PM
OLE Object Type? j.gonsalves@ntlworld.com Access VBA 1 October 20th, 2004 02:16 PM
Displaying OLE object field in a form Rick Neifeld Access VBA 0 December 24th, 2003 02:16 PM





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