MS Access Treeview error loading ActiveX control

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Mat Son
    New Member
    • Jul 2011
    • 7

    MS Access Treeview error loading ActiveX control

    recently an error appeared with a Treeview element in my access form.

    The expression Expand you entered as the event property setting produced the following error: There was an error laoding an ActiveX control on one of your forms or reports.

    When I click "OK" (only opportunity) the next error appears (Expand is replaced by MouseMove, MouseDown/Up, DblClick etc.), when I press Keys the KeyDown/Up/Press Message appears etc. When I interact with the TreeView then the "Expand" is replaced by e.g. NodeClick or Collapse. Every message only appears once, when I performed every possible Event no message pops up - but the treeview doesnt work, it doesnt open any form (the treeview is used as a menu).

    The mysterious thing to me is - last week those Access Databases all worked fine - we have a database for every customer (frontend and data together) and now suddenly every database 'crashes'. I assumed that the ActiveX Treeview Control was changed by a Windows Update or something similar but also an old WinXP laptop throws the same error messages. Even a database that hasnt been opened for 2 weeks and definitely worked back then doesnt work anymore. So from my point of view there cant be anything in the code that is wrong.

    Nevertheless I tried to set a breakpoint in the Form_Load event, but the Expand Error already pops up before the first line of OnLoad is executed. The OnLoad Event is the only event that is specified (GUI says "Event Procedure", its VBA Code only) and all other fields are blank (and no code specified). I created a blank VBA for e.g. MouseMove, but the error still appears.

    What is this error and where does it come from? Hope anyone can help.

    Regards,

    Matthias
    Last edited by zmbd; Aug 20 '12, 02:56 PM. Reason: Made the error message easer to read without scrolling.
  • Mat Son
    New Member
    • Jul 2011
    • 7

    #2
    My Treeview Project 5

    via this URL there is a sort of "tutorial" where someone makes use of the treeview in access.
    When I download his files the same errors appear. So I think it definitely has to do with the Treeview-ActiveX controls.
    Do the files work at your computer? If so, why so?
    Hopefully someone has an idea..

    Comment

    • zmbd
      Recognized Expert Moderator Expert
      • Mar 2012
      • 5501

      #3
      The one form I've played with seems OK; however, I haven't used this control much.... I did however, find a file here: http://www.psci.net/gramelsp/TreeviewSample.zip that when unpacked worked just fine with my local installs.

      It may be that the updates haven't cycled thru our systems yet (typically over the weekends when they hit) so if this changes on Monday or later this week, I'll post back.

      -z

      Comment

      • TheSmileyCoder
        Recognized Expert Moderator Top Contributor
        • Dec 2009
        • 2322

        #4
        If it is only affecting your computer I would try a re-install.

        If it was only affecting a single form/datebase my guess would be that the database had become corrupt and you could try decompiling it and then a Compact+Repair and a recompile.

        Comment

        • TheSmileyCoder
          Recognized Expert Moderator Top Contributor
          • Dec 2009
          • 2322

          #5
          I just stumpled accross this in the Professional Microsoft Access Developers' Network (PMADN)


          Luke Chung
          • We just published a detailed paper describing this issue, some of the symptoms, and how to address it entitled:

          Fixing the Microsoft Windows Common Control Library (MSCOMCTL.OCX) Security Update


          It details how the suggestion in the KB article (http://support.microsoft.com/KB/2687441) fails, and a workaround that involves:

          •Installing an older version of the control
          •Registering it
          •Unregistering it, and
          •Re-registering the updated one

          What a hassle. Hope this helps

          I haven't tested his solution, since I don't (yet) have a problem with the treeview, but Luke and his firm does alot of good work, so I would suggest checking it out.

          Comment

          • ellwood929
            New Member
            • Feb 2008
            • 1

            #6
            Originally posted by TheSmileyCoder
            I just stumpled accross this in the Professional Microsoft Access Developers' Network (PMADN)





            I haven't tested his solution, since I don't (yet) have a problem with the treeview, but Luke and his firm does alot of good work, so I would suggest checking it out.
            I've just tested this out. I just did the unregister and register of the new mscomctl.ocx and it worked!! Have been tearing my hair out over this for a couple of days, so many thanks for posting this!!! Very relieved and grateful :)

            Comment

            • TheSmileyCoder
              Recognized Expert Moderator Top Contributor
              • Dec 2009
              • 2322

              #7
              I can only imagine the frustration you must have felt. I think 95% of my applications would not be usuable without the treeview, I use them extensively, and so much functionality are tied into the treeview and its events.

              Comment

              Working...