Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On Monday, August 31, 2009 at 3:26:16 AM UTC+5:30, Chip Pearson wrote:
I would use a VBScript rather than an exe file. Open Notepad, and enter the following in the text file: Set XL=CreateObject("Excel.Application") XL.Visible=True XL.Workbooks.Open "C:\A.xls" XL.Run "A.xls!TheMacro" Change "C:\A.xls" to the appropriate file name. Change "A.xls!!TheMacro" to the workbook name and macro name. Save the file as a vbs file, e.g., RunIt.vbs rather than a txt file. Then, all the user needs to do is double click the vbs file and Excel will start, open C:\A.xls and execute TheMacro. Cordially, Chip Pearson Microsoft Most Valuable Professional Excel Product Group, 1998 - 2009 Pearson Software Consulting, LLC www.cpearson.com (email on web site) On Sun, 30 Aug 2009 04:54:01 -0700, Pawan wrote: Hi I have written a complex macro in excel and now have to distribute it to co-workers. However, I want to create an executable file which will run the macro directly (will open the userform in my macro). Is there any chance of doing so? Thanks in advance Regards, Pawan Thanks a lot Chip for this solution, however if i want to run a macro using using this and also want to pass parameters, how can i do that? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Create executable file to run excel macro | Excel Programming | |||
getting an excel file to run as an executable | Excel Discussion (Misc queries) | |||
How do I create an executable excel file? | Excel Programming | |||
Excel file as an executable? | Excel Programming | |||
Is there a way to make Excel file an executable? | Excel Programming |