Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I've just briefly tested a horrible kludge using a batch file and an
environment variable. This is tested on Windows XP only, with the call made from a desktop shortcut, or from shell within VB5. I created a 2-line batch file, callXL.bat set xl_command_line=%2 %3 %4 %5 %6 %7 %8 %9 %1 I then call the batch file with the workbook path as the first parameter, followed by any other parameters (in a shortcut) C:\callXL.bat "C:\SJGtest.xls" hello world (or from VB) Shell "C:\callXL.bat ""C:\SJGtest.xls"" hello world" and, in the workbook, it is retrieved using: Private Sub Test() MsgBox Environ("xl_command_line") End Sub riveaira < wrote: I would LOVE to know how to do this too! Has anyone found a way? ;) --- Message posted from http://www.ExcelForum.com/ |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Are there command line parameters for Excel? | Excel Discussion (Misc queries) | |||
What are the possible command-line arguments in Excel? | Excel Discussion (Misc queries) | |||
command line Excel Script | Excel Discussion (Misc queries) | |||
command line excel to run macros | Excel Programming | |||
Command line parameters into a macro | Excel Programming |