yannis Posted April 5, 2009 Report Share Posted April 5, 2009 In a MEP macro I am using an Excel file in which I embed a microsoft macro (VBA Sub). I try to call the sub but MEP cannot find it. So for now to get to the sub I click in excel Tools\Macro\... How can I get the sub directly ? Please help yannis Quote Link to comment Share on other sites More sharing options...
kevin Posted April 6, 2009 Report Share Posted April 6, 2009 How would you call the Excel macro manually? Do that in the Macro Express Pro macro. Quote Link to comment Share on other sites More sharing options...
Cory Posted April 6, 2009 Report Share Posted April 6, 2009 I once launched VBA macros in some Office app using the command line. I think it was Excel but I can't be certain. Might try that. I think I even posted about it back in the ME3 forum. But that was some time ago. Quote Link to comment Share on other sites More sharing options...
yannis Posted April 6, 2009 Author Report Share Posted April 6, 2009 I tried using "Program Launch" with Application.Run "C:\XFIL\ER.xls!optimize" It should have worked because MEP accepted it (when I left something out will get "specify file") and still I was getting at run time "cannot locate file) Finaly I solved the problem by using the MS macro's short-cut and Text type <CONTROL><SHIFT>N Thanks for your help Quote Link to comment Share on other sites More sharing options...
Cory Posted April 6, 2009 Report Share Posted April 6, 2009 Sometimes you will need to actually specify the EXE in the run line of Application run and the parameters like the file name and macro in the parameters field. I don't know why this is but in same cases it seems necessary. Quote Link to comment Share on other sites More sharing options...
yannis Posted April 7, 2009 Author Report Share Posted April 7, 2009 Cory, There is no problem provided: 1. You store the MS macro in the workbook that contains the worksheet and you don't use the same Shortkey in the workbook 2. In the MEP file you don't use the same Hot Key for another MEP macro Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.