Excel Command Line Switches

The following text was copied from the Microsoft Site at:

http://support.microsoft.com/support/kb/articles/Q211/4/81.ASP

Switch Function
----------------------------------------------------------------------

/e, /embedded Forces Excel to start without displaying the
startup screen and creating a new workbook
(Book1.xls).

Example: /e, /embedded

/m Forces Excel to create a new workbook that
contains a single macro sheet.

Example: /m

/o Forces Excel to re-register itself. Specifically,
the following key is rewritten in the registry:

HKEY_CURRENT_USER\Software\Microsoft\Office\9.0\Excel

NOTE: If this key contains invalid values, they are
not corrected by using this switch. This switch only
replaces missing values.

Example: /o

/p Forces Excel to use the path you specify as the active
path rather than the default path.

Example: /p "C:\Windows"

/r Forces Excel to open the specified file in
read-only mode.

Example: /r "C:\My Documents\Test.xls"

/s Starts Excel in Safe mode. ("Safe Mode" will appear in
the Excel title bar.) Safe mode starts Excel as if it is
the first time after Setup.

Safe mode bypasses the following:

- All files in any Excel startup folder.

For more information about the location of startup
folders, please see the following article in the
Microsoft Knowledge Base:

Q240150 XL2000: How to Use Excel Startup Folders

- Add-ins: The Addins dialog box still displays the
selected addins. However, the addins are not loaded.

- Excel toolbars (Excel.xlb or .xlb): The
original installation default toolbar settings are
used.

- Excel specific registry information: The original
installation default registry settings are used.
Registry information can include the following key and
other keys:

HKEY_CURRENT_USER\Software\Microsoft\Office\9.0\Excel\Options

NOTE: When Excel is in Safe mode, the Options dialog
box displays the default settings, not your customized
settings.

/regserver Forces Excel to register itself and then quit. Use this
switch when you want Excel to rewrite all of its
registry keys and reassociate itself with Excel files,
such as workbooks, charts, and so on.

Example: /regserver


/unregserver Forces Excel to unregister itself and then quit.

Example: /unregserver

 
Template design by venus soft
Copyright © 2008 Venus Soft