Excel UserForm Object Required error 424

Important Notice


Please note that on 14th December 2023 users will experience an expected outage whilst we make upgrades to our network. We anticipate this process may take a couple of hours and so we apologise in advance for any inconvenience.

  • I'm unsure why my Excel code is not working today. I have previous code that is working, but now I have this error.


    I have a button that when clicked on executes this code:


    Code
    Sub Rectangle1_Click()    new_case_entry.Show
    End Sub


    My form object in VBA is named new_case_entry. This was never changed. I ran a diff on the code and there are no changes other than some modifications to data parsing. The only error that appears is Runtime error 424: Object required. And the error occurs on new_case_entry.Show. It does not give me any additional information. Any clues? Otherwise I will have to re-edit the working excel sheet and re-add the changes.


    Thanks.

  • Re: Excel UserForm Object Required error 424


    In my experience, when the code stops running and highlights the .Show line, the error is actually in the form code. You can try to step through the code to see where the problem is. Place a breakpoint (F9) on the .Show line and step through (F8) until you get the 424 error within the form code.

  • Re: Excel UserForm Object Required error 424


    Quote from shknbk2;767225

    In my experience, when the code stops running and highlights the .Show line, the error is actually in the form code. You can try to step through the code to see where the problem is. Place a breakpoint (F9) on the .Show line and step through (F8) until you get the 424 error within the form code.


    Thanks. Didn't know it was capable of doing that. I ended up copying newly added code to my old working file to get it working again, but I'm going to try the debugging to see what happens.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!