# Macro won't run unless editor is open



## bravura

Hope this is a quick fix?
on my form i have several buttons with event procedures that call a macro. they won't run unless i have the editor open - it just has to be open - and when it's open i can run macros perfectly fine from the form.


----------



## davesexcel

Where is the code and what is the code?


----------



## Micron

In the property sheet with the form (?) open in design view, click on the ellipses for the button click event and see if it takes you to the correct procedure. By "macro" I'm assuming you're referring to a written procedure and not an actual macro. Since this is an Access question, macros are not the same thing in Access as they are in Excel.
The message is saying that there's no connection between what you have in the property sheet and any event, or there is an issue with the code in the event. In my mind and based on that, it shouldn't work whether or not the editor is open.


----------



## bravura

VBA Code:
__


Private Sub cmdHOReport_Click()

    Call ReportsExternal.Reports(0)

End Sub


Private Sub cmdTLReport_Click()

    Call ReportsExternal.Reports(1)

End Sub


Private Sub cmdTSReport_Click()

    Call ReportsExternal.Reports(3)

End Sub



*et cetera.



*


----------



## bravura

I fixed it. this problem happened before and i managed to fix it and i remember what happened. afterr deleting some tables, i had some queries that depended on them. i deleted the queries and it runs fine now.


----------



## bravura

Thanks for your help. this MrExcel Forum has no peers.


----------

