Results 1 to 23 of 23

Thread: Excel: How to: Pass Command Line Parameter [DKenny is KING!]

Threaded View

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    May 2004
    Location
    Carlisle, PA
    Posts
    1,045

    Resolved Excel: How to: Pass Command Line Parameter [DKenny is KING!]

    Esteemed Forum Participants and Lurkers:
    ===============================
    Excel 2003 VBA

    I vaguely recall having done this somewhere in the way distant past ... can I pass a general purpose variable (department name string in this case) as a Command Line Parameter to Excel? Right now I have 6 different workbooks for 6 departments with macros, and I want to consolidate them all into one workbook with 6 shortcuts, where the shortcut provides the department via a Command Line Parameter. Except for the department name and folder path, the Macro is identical for each department. I know I can specify a startup file in the Command Line, but can I use a general purpose parameter? Isn't there some way to fetch the parameter in the Workbook Open event?

    Is there perhaps an API call that can fetch the command line so that I can extract my parameter?
    Last edited by Webtest; Nov 8th, 2005 at 04:17 PM.
    Blessings in abundance,
    All the Best,
    & ENJOY!

    Art . . . . Carlisle, PA . . USA

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width