Article sections

    Introduction

    Setup packages created with InstallForge initialize a set of environment variables during runtime. These variables can be used for Custom Commands in order to perform more complex tasks during the installation of your application.

    Environment Variables

    The following table lists the supported environment variables.

    Table Table
    IF_APPLICATION_NAME Application name provided in the InstallForge Builder Environment when creating a setup package (see the Product Name field)
    IF_APPLICATION_VERSION Application version provided in the InstallForge Builder Environment when creating a setup package (see the Product Version field)
    IF_COMPANY_NAME Company name provided in the InstallForge Builder Environment when creating a setup package (see the Company Name field)
    IF_INSTALLPATH Installation path selected by the user on the Select Application Folder dialog of the setup
    IF_LANGUAGE Language selected by the user at startup of the setup. The content of this constant corresponds to the name of the language file without extension as it was defined when building the setup package. When setup package is monolingual, the content will be empty.
    IF_ORGANIZATION Organization entered by the user on the setup serial validation dialog
    IF_SERIAL Serial entered by the user on the setup serial validation dialog
    IF_USERNAME User name entered by the user on the setup serial validation dialog

    Example

    In this example, a text file containing the application version as a string will be created during the installation by using the Custom Commands feature and the IF_APPLICATION_VERSION environment variable.

    Please complete the following steps:

    1. In the InstallForge Builder Environment, click General in the explorer bar and enter a version in the Product Version field.
    2. Click Commands in the explorer bar, click Add… on the Commands tab widget.
    3. On the Edit Command window, select Shell Execute as command type.
    4. In the Command field, enter: echo %IF_APPLICATION_VERSION% > “<InstallPath>\version.txt”
    5. Click Ok on the Edit Command window.

    in How-To’s
    Did this article answer your question?