Hello,
I'm trying to record a macro that runs a macro. I have two sheets in my workbook. I'm on sheet 1 and move to recordedPositions. The I want the macro to run. I can manually go to sheet recordedPositions cell A4 and then manually run the macro and it all works fine. I want a one click action to do this. After I stop recording this is what I get. Just a reminder this is in Excel.
Sub restoreMainTable()
'
' restoreMainTable Macro
'
'
Sheets("recordedPositions").Select
Range("A4").Select
End Sub
I tried to add this line of code
DoCmd.runMacro "ResetFromRecorded"
Then it yells at me with the error of
Run-time error '424
Object required
I have no clue what to do. I tried
Dim x as object
x.Docmd.runmacro "my macro" that doesn't work.
Any advice?
I'm trying to record a macro that runs a macro. I have two sheets in my workbook. I'm on sheet 1 and move to recordedPositions. The I want the macro to run. I can manually go to sheet recordedPositions cell A4 and then manually run the macro and it all works fine. I want a one click action to do this. After I stop recording this is what I get. Just a reminder this is in Excel.
Sub restoreMainTable()
'
' restoreMainTable Macro
'
'
Sheets("recordedPositions").Select
Range("A4").Select
End Sub
I tried to add this line of code
DoCmd.runMacro "ResetFromRecorded"
Then it yells at me with the error of
Run-time error '424
Object required
I have no clue what to do. I tried
Dim x as object
x.Docmd.runmacro "my macro" that doesn't work.
Any advice?