Results 1 to 6 of 6
  1. #1
    reinharw is offline Novice
    Windows 8 Access 2013
    Join Date
    Jul 2015
    Location
    Oregon
    Posts
    4

    Missing VBA Object

    I'm trying to add a new form and report to an existing Access 2013 database I'm using to manage a photocard collection. I'm running into a problem with the VBA code necessary to create thumbnails for the form and report I'm trying to create. Here is the single line of code I'm trying to implement to generate a thumbnail, On Exit event.


    Private Sub Picture7_Exit(Cancel As Integer)
    If Picture7.Changed Then Preview.Value = Picture7.PreviewOLE(64) 'Creates thumbnail photo upon exiting the form
    End Sub


    Picture7 identifies the object from my product table for the OLE Photo.




    Preview identifies the object from my product table for the Binary Object created for the thumbnail.


    Here is my problem. The VBA on exit event module recognizes Picture7 as an existing object (Intellisense list and turns blue it as soon as I type the period after Picture7) but does NOT recognize Preview in the same way. Not surprisingly, I get the following error, Run-Time error '424': object required, when the code attempts to execute.


    Both are existing objects/fields in my products table.


    I know it works because I've created several new small test databases using the same product table and field names and when I create the module with the code above, intellisense recognizes both objects (Picture7 & Preview) without fail and it executes perfectly.


    So, my question is why is my existing DB, not discovering/recognizing/finding the Preview object. What do I have to do so it will?


    Hopefully, I've given enough detail to understand my problem. If I haven't, please ask for details to clarify the issue. This problem is driving me crazy. Thanks.


    Bill

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,771
    Never done anything like this. Can you provide working test database for exploration and see if I can get it to work with my existing db? That might lead to solution for your situation.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    reinharw is offline Novice
    Windows 8 Access 2013
    Join Date
    Jul 2015
    Location
    Oregon
    Posts
    4
    Will do. Thanks. I'll get it out tomorrow.

  4. #4
    reinharw is offline Novice
    Windows 8 Access 2013
    Join Date
    Jul 2015
    Location
    Oregon
    Posts
    4

    Troublesome & Experiemental Database

    June7

    FYI: I'm struggling uploading the problematic DB (41 MB). I don't know why but I'll keep trying to figure out my problem. Until then you can look at the experimental DB until I can get you the other. Sorry for the delay.

    Bill

    As you suggested, I've attached three files for you to play with:


    Cards_OE - this is the troublesome DB
    Cards_Experimental - this is the DB I created using the same general structure and VB code with no problem. It works exactly as it is designed to.
    Pictures_Experimental - Folder with some sample pictures for you to use if necessary


    The problematic code in the Cards_OE DB is on the Products Form associated with the lower lefthand activeX object. If you check the properties of this object on the events tab, you'll see the code I'm having problems with.


    As for the working Cards_Experimental DB, the corresponding form as above is on the FrmProduct. It has the same activeX component with the same code on the event tab.


    You're probably wondering what is supposed to happen and actual does in the Cards_Experimental DB. Here is what happens when you make a new entry on the FrmProduct (PictureName, Subject, DateCreated & photo). When you exit the FrmProduct form, a thumbnail of the photo you entered is generated and recorded as Preview in the TblProduct table. You can check that it does by looking in the Preview field in the table or opening the FrmProducts form. It is a continuous form showing all the data with corresponding thumbnails. That's how it is supposed to work.


    Finally, as I mentioned above, the code is connected to an ActiveX module which generates the thumbnail as well as other things. It may need to be installed for my DB (either) to operate because I don't know if it travels along with the DB. Here is the URL in case you need it. Access Imagine: http://access.bukrek.net/download


    Let me know what you find out. Also, if something above doesn't make sense, shoot me a note and I'll try to explain better. Here's wishing you good luck. Thank you in advance for the help.


    Bill
    Attached Files Attached Files

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,771
    Well, I am dead in the water. My home internet too slow for downloading that ActiveX and I am blocked at work. If I can get to another internet source and download, will resume investigation. However, my one attempt to install a dll add-in for Access on my home PC, failed.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  6. #6
    reinharw is offline Novice
    Windows 8 Access 2013
    Join Date
    Jul 2015
    Location
    Oregon
    Posts
    4
    June7,

    I understand and appreciate your efforts. I'll keep an eye on the forum and hope you're willing and able to find a work around. Again, thanks. Bill

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Shockwave Flash Object Missing
    By pivoine in forum Access
    Replies: 1
    Last Post: 03-26-2015, 12:32 PM
  2. Missing Object library and .dll
    By tmcrouse in forum Forms
    Replies: 1
    Last Post: 06-23-2014, 06:17 PM
  3. Accessing a table with a missing object
    By kewelch in forum Programming
    Replies: 3
    Last Post: 06-21-2013, 12:50 PM
  4. Forms missing from Object Browser
    By hertfordkc in forum Access
    Replies: 1
    Last Post: 10-17-2011, 05:18 PM
  5. Missing object .from
    By jmclemore in forum Access
    Replies: 3
    Last Post: 02-09-2011, 07:23 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums