我有一个工作簿打开另一个工作簿(文件名基于单元格值),然后在该文件中运行一个名为Single_sector的宏.
它打开文件完全正常,但不运行宏.有任何想法吗?
Sub run_all()
Dim Location
On Error Resume Next
'Location of file to open
Location = Worksheets("Main").Range("folder_location").Value
'Open F&V File
Application.Workbooks.Open Location & Range("fv_file").Value
'Run Macro
Run ("Single_sector")
End Sub
Run Code Online (Sandbox Code Playgroud)