MORE INFORMATION
The following command-line switches and options are used
with the Setup command line. By using command-line options, an administrator
can control how programs that use the Microsoft Windows Installer package (.msi
files) and the transforms (.mst files) install software
applications.
If you plan to use several Setup properties, type them
in the Setup settings file (Setup.ini) to reduce the chance of encountering a
command-line length limitation.
For more information about Setup
switches and properties, see the Microsoft Office 2003 Resource Kit. To view
the Microsoft Office 2003 Resource Kit, visit the following Microsoft Web site:
Important Notes
- Switches and options are not case sensitive. For example,
/A is the same as /a.
- Except where specifically noted, you can use these switches
only when you perform an initial installation of Office 2003.
- If you use a Setup command-line option that is also used in
the Setup settings file (Setup.ini) or in the transform (.mst file), the
command-line switch typically takes precedence.
- The Windows Installer package (.msi file) must be in the
same folder as Setup.exe. When you install Microsoft Office, the Windows
Installer package must be in the root folder of the administrative installation
point.
- When you use multiple switches, separate them with a blank
space. For example, use the following command line to use a specific installer
file and write the results to a log file: Setup /i Pro11.msi /l*
c:\logfile.txt
- When Setup.exe ends, it sets %errorlevel% if an error was
encountered. If the user cancels the setup process, the error level that is
returned is zero (0), indicating that no error occurred.
/a msifile
The
/a msifile switch creates an administrative installation point for the
specified package (.msi file). The package must be in the same folder as
Setup.exe; both the package and Setup.exe must be at the root of the
administrative installation point.
Example:- /a My.msi
- /a "subfolder1\My.msi"
/f optionsmsifile
The
/f optionsmsifile switch forces repair of a program that is associated with the
specified package (.msi file). The package must be in the same folder as
Setup.exe; both the package and Setup.exe must be at the root of the
administrative installation point. Alternatively, you can specify the product
code for the package. You can copy the product code from the Product section of
the Setup settings file.
Note You must specify the same package that was used to install the
program originally.
Valid values for
options include the following:
Switch | Description |
a | Force reinstallation of all files regardless of
checksum or version. |
c | Reinstall file if missing or corrupted. |
d | Reinstall file if missing or a different version is
present. |
e | Reinstall file if missing or an equal or older
version is present. |
m | Rewrite all required HKEY_LOCAL_MACHINE registry
entries. |
o | Reinstall file if missing or an older version is
present. |
p | Reinstall file only if missing. |
s | Reinstall all shortcuts and overwrite existing
shortcuts. |
u | Rewrite all required HKEY_CURRENT_USER registry
entries. |
v | Retrieve the package from the original source and
recache it on the local computer. |
Important If a user applies a client (binary) update to a computer, you
cannot use the
/f switch to recache and reinstall on that computer from an updated
administrative installation point. In this case, users must remove and
reinstall from the updated administrative image.
Example:- /focums My.msi
- /fvm {12345678-1234-1234-1234-123456789123}
/i msifile
The
/i msifile switch installs applications using the specified package. The
package must be in the same folder as Setup.exe.
Note By default, Setup.exe directs Windows Installer to perform the
same function as /i.
Example:- /i My.msi
- /i "subfolder1\My.msi"
/j option msifile /t mstfile
The
/j option msifile /t mstfile switch advertises the program on the computer and installs the
program on first use. You must specify an option to advertise the program to
either the computer or the user. You can use the
/j switch only when you run the setup from an administrative
installation point or an image of the CD on the network. If no package is
specified, the setup uses the package specified in Setup.ini. To apply a
transform to the advertised program, use the
/t switch and specify an .mst file.
Valid values for option
include the following:
Switch | Description |
m | Advertise to all users on the computer. |
u | Advertise to the current user. |
Note In addition to
/t, you can use the following three command-line options when you
use
/j to advertise the program:
/l,
/q, and
/settings.
Example:/l optionslogfile
The
/l optionslogfile switch creates a log of installation actions for the setup
process and a log file for each Windows Installer task. The
/l switch also overrides default settings specified in the Logging
section of Setup.ini.
Values for this option include the following and
capture the corresponding data:
Switch | Description |
a | Start of action notification |
c | Initial UI parameters |
e | Error messages |
i | Information-only messages |
m | Out-of-memory messages |
o | Out-of-disk-space messages |
p | Property table list in form property=value |
r | Action data record; contains action-specific
information |
u | User request messages |
v | Verbose includes debug messages |
w | Warning messages |
* | Turn on all logging options except v |
+ | Append to existing log file |
! | Writes each line to the log file. The default
behavior is to cache 20 lines of log file text
into memory and then write 20 lines to the log
file at the same time. This is done to improve performance. |
Logfile signifies the name and path of the log file to create.
When you include (*) in the log file name, the setup process creates a unique
file name for each instance of the setup process.
Example: /lv* "%temp%\MyApp Setup(*).txt"
This command line creates
the following log files:
- Setup.exe log file "%temp%\MyAppSetup(0001).txt"
- Windows Installer log file for core packages
"%temp%\MyApp(0001)_Task(0001).txt"
/m .mif file
The
/m switch specifies an SMS .mif file name of 8 characters or less.
Note Do not include the .mif file name extension with the file name. If you do, the command will return the following error: "Invalid command line."
/noreboot
The
/noreboot
switch specifies to not restart the computer or display a restart
dialog box at the end of the installation. The
/noreboot option sets the Windows Installer REBOOT property to
ReallySuppress for each package included in the installation except the last
one.
/p mspfile
The
/p mspfile switch specifies to apply an administrative update (MSP file) to
a client installation. You can also use the
/p to apply an update to an administrative installation by including
the /a option and the name and path of the .msi file on the administrative
installation point. To apply the update quietly, include
/qb on the command line to generate a log file, include
/l.
Example:- msiexec /p mspfile /qb
/loptions
- msiexec /p mspfile /a
msifile/qb /l
options
/q option
Set the Setup user interface display level.
Valid values for
options include the following:
Switch | Description |
b | Display only simple progress indicators and error
messages (basic). |
f | Display all dialog boxes and messages; equivalent
to omitting the /q option (full) |
n | Display no user interface; equivalent to specifying
/q with no options (none). |
r | Display all progress indicators and error messages
but collect no user information (reduced). |
- | Suppress all modal dialog boxes; used only with b.
|
+ | Add completion message to the n or b option. |
Note The completion message appears only when the setup process does
not have to restart the computer after the installation.
/settings file
The
/settings file switch specifies a custom Setup settings file for Setup.exe to
use instead of Setup.ini. The settings file must be in the same folder as
Setup.exe, or the path must be included on the command line.
Example:/settings MyApp.ini /x [msifile]
/wait
Wait for the installation to complete before you quit the Setup
program.
/x msifile
The
/x msifile switch removes the program associated with the specified package.
The package must be in the same folder as Setup.exe, and both must be at the
root of the administrative installation point.
Note You must specify the same package that was used to install the
program originally.
Example:: /x My.msi
property=value
Specify a property value on the command line. If the value
contains spaces, enclose it in quotation marks ("). To specify two or more
property-value pairs, separate them with spaces. The following are examples of
this switch:
ALLUSERS=string | Install
program for all users of the computer or for only the current user. By default,
Windows Installer installs for all users of the computer. Setting ALLUSERS to a
null value ("") overrides this default behavior and installs per user. 1=
Install for all users of the computer; requires administrative credentials.
2= Install for all users of the computer. "" = Install only for the
user running the setup process. ALLUSER="" |
CDCACHE=string | Specify
the level of caching. Auto= cache based on available disk space 1=
cache only what you install 2= cache all of the source 0= cache
disabled CDCACHE= auto |
COMPANYNAME=string | Specify
an organization name. COMPANYNAME=My Business |
INSTALLLOCATION=string | Specify
the installation location. INSTALLLOCATION=C:\Program Files\MyApp |
LOCALCACHEDRIVE=string | Specify
the drive that the installation files will be cached to. LOCALCACHEDRIVE=C
|
PIDKEY=string | Enter a
25-character volume license key on the Setup command line or in the Setup
settings file. When you set the PIDKEY property, users do not have to enter a
product key when they install. PIDKEY=123467890123456789012345 |
TRANSFORMS=string | Specify
a transform to apply to the
installation. TRANSFORMS=\\server\share\myApp\Custom.mst |
USERNAME=string | Specify a
default user name. |