Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Forums   Help   Contact   Merch   Join   Order   Logon  
 
Back to Access Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Imaging Seminar Drag Drop
Eric Michalek 
    
6 years ago
Quick question for OLE boxes.
-Drag and drop, I have Access 2016, it lets me drag and drop directly into my OLE boxes.
-Watching the seminar, I get the feeling that older versions of access did not let you drag and drop.

Is this correct?
Richard Rost  @Reply  
          
6 years ago
That's correct. Older versions would not let you do that, and OLE Objects are pretty much the only objects that support drag-and-drop even in newer versions. You can't, for example, drag and drop items between list boxes. I tried for a LONG time to figure out a way to do that.
Eric Michalek OP  @Reply  
    
6 years ago
After watching the imaging seminar several times I can't figure out the code (because the seminar doesn't cover drag and drop and only briefly covers OLE objects like PDF files in lesson 19.)
-For pictures, the seminar covers how a command button copies a picture from their desktop or CD, loads it on the share drive, leaving a link so the picture displays in the image box.
I want to do the same thing for a PDF file
(Since newer versions of access have the capability to drag and drop. I need to give users that ability to drag and drop the PDF into the bound object frame, and then the command button changes the file from embedded to linked with copy created on the share drive)
(Supervisors will approve this record on another form.  It will contain a bound object frame displaying the linked PDF.  When they click a command button on the form, the file will be moved to different location on the server (a secure folder as discussed in the seminar where users can view but not delete or modify
Richard Rost  @Reply  
          
6 years ago
You know what... I've never done that before. Let me experiment with it for a bit. I'm finishing up the Genealogy Seminar today and then I'll put it on my list.
Richard Rost  @Reply  
          
6 years ago
OK, Erik, I did my homework. I spent an hour today researching this for you. I stand by my original view that it's a bad idea to use OLE Objects. Yes, they give you drag-and-drop capability, but if you can convince your users to simply click on a button and select a file, and then you can do whatever you want with that file.

Every article I read today stresses that OLE is an old technology and developers should be moving away from it. Microsoft only includes it in new versions of Access for backward compatibility. Essentially, Access "packages" files inside of headers and other nonsense for storage. It makes extracting them VERY difficult. This article is an especially good read on how this works: OLE and Accessing Files Embedded in Access.

I've found some VBA code that's decent at extracting Word and Excel documents that have been stored in OLE Objects. That's because Microsoft provides DLL libraries for those file types. PDFs are a much more difficult issue. I found some Visual Studio code but it's pretty in depth and I'm not sure (a) if it works, or (b) if you can convert it to VBA.

Likewise here is some code that supposedly works but only on MDB files, not ACCDB files. I suppose you could save a database as an MDB for the purposes of copying PDF files, and then link it to your main database, but that seems like a lot of work.

In a nutshell, I tried to find an easy, workable solution for what you want to do, and I couldn't. I understand what you're trying to do. Here's what I suggest:

1. Create a field to store the FILENAME for the PDF file in your user table (let's call it the ADD table)
2. Give the user a button to select the PDF and add it to the ADD table
3. Your code can copy the file to an "unapproved" folder, possibly one specific to that user
4. Make sure your admins have read/write access to the ADD folder (or each user folder)
5. When the PDF is approved, your code can MOVE it to a central LIBRARY folder that everyone has READ access to
6. The path is updated in the database to its new location.

That is what I recommend.
Richard Rost  @Reply  
          
6 years ago
If simulating the drag-and-drop experience instead of using a button and a dialog to pick a file, then Alex came up with a really cool method for how we can simulate a drag-and-drop box on an Access form. It's too much to go into here, but I'm going to add it to the next class for you.

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Access Forum.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 5/1/2026 7:20:10 PM. PLT: 0s