Pre-build/Post-build Event Command Line Dialog Box

Clicking the browse (...) button of the PreBuildEvent or PostBuildEvent property for a deployment project brings up the Pre-build or Post-build Event Command Line dialog box.

Remarks

You can type pre- or post-build events directly in the edit box, or you can select pre- and post-build macros from a list of available macros.

Pre-build events do not run if the project is up-to-date and no build is triggered.

UI Element List

  • Command line edit box
    Contains the events to run either for pre-build or post-build.

  • Macros
    Expands the edit box to display a list of macros to insert in the command-line edit box.

  • Macro table
    Lists the available macros and its value. See "Macros" below for a description of each. You can select only one macro at a time to insert into the command-line edit box.

  • Insert
    Inserts into the command line edit box the macro selected in the macro table.

Macros

You can use any of these macros to specify locations for files, or to get the actual name of the input file in the case of multiple selections. These macros are not case-sensitive.

Macro

Description

$(BuiltOutputPath)

The absolute path name to the output file directory.

$(Configuration)

The name of the current project configuration, for example, "Debug".

$(ProjectDir)

The directory of the project (defined as drive + path); includes the trailing backslash '\'.

See Also

Reference

Deployment Properties

PreBuildEvent Property (Windows Installer)

PostBuildEvent Property (Windows Installer)

RunPostBuildEvent Property (Windows Installer)