Error 2585 - This action cannot be carried out

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Killer42
    Recognized Expert Expert
    • Oct 2006
    • 8429

    #16
    Originally posted by Andrew Thackray
    Another error in the code. The first cnt loop has a limit of 99. It should be 499. I made the array large because I suspected that there may be recursive calls and I wanted to see how deep the recursion went.
    You mean I missed a bug? Boy, is my face red! :)

    In my defense, I didn't actually read the code. Just glanced at the comments.

    Comment

    • robjens
      New Member
      • Apr 2010
      • 37

      #17
      I actually ran into this error for the first time when I was trying to close a form while a class module function was changing the page on a tab control. Solved it by simply saving a boolean that it should close and check for it's value after the tabpage change function took place. Perhaps someone who didnt think of this obvious solution like me in the first place may find use of this tip.

      Comment

      • NeoPa
        Recognized Expert Moderator MVP
        • Oct 2006
        • 32662

        #18
        We often have members, and other public users, who go through threads looking for answers. This includes many threads that haven't been actively updated for years, but that doesn't mean they're not still in use.

        Thanks for posting & Welcome to Bytes!

        Comment

        • jconley
          New Member
          • Nov 2015
          • 1

          #19
          I had a very similar problem to the one in the original post, and Killer42's suggestion above was very helpful. I stepped through my VBA code (MS Access 2007) to find the buggy code I needed to delete and that was causing the close action to fail. Thank you so much! This bug had been sitting in my code for years. I had previously put a band-aid on it until this morning when a user told me the application was crashing when they tried to open it.

          Comment

          • kkarbasian
            New Member
            • Aug 2021
            • 1

            #20
            hi
            i had this error same and it is very simple in end of vba window had somthing note please delete them retype your code and ...

            Comment

            Working...