Java environment variables

This section describes the environment variables that need to be set when you load your Java application with UFT Java Add-in support. For example, some environment variables need to be set to the path name of the Java Add-in support classes folder.

Note: Most of these variable values are set automatically by UFT, and you can simply verify their correctness. Alternatively, if you needed to modify these variables for any reason, use the instructions below to return them to the values required by UFT.

To work, or stop working, with Java IBM versions 1.7 or 1.8, manually modify the JAVA_TOOL_OPTIONS environment variable as described below.

  1. Set the _JAVA_OPTIONS environment variable (Oracle) or the IBM_JAVA_OPTIONS environment variable (IBM) as follows:

    Xbootclasspath/a:"C:\Program Files (x86)\Micro Focus\Unified Functional Testing\bin\java_shared\classes\jasmine.jar

    The above settings should appear on one line (no newline separators).

  2. Depending on the Java environment you are using, set the JAVA_TOOL_OPTIONS environment variable: 

    Java version

    Variable value

    Oracle Java


    IBM Java versions 1.7 or later

    -agentlib:jvmhook -Dmic.enforce=ibm

    Tip: If needed, temporarily remove Java support by renaming the _JAVA_OPTIONS / IBM_JAVA_OPTIONS and JAVA_TOOL_OPTIONS environment variables. For example, you must remove Java support if you want to test ActiveX controls that are embedded in SWT- or Eclipse-based applications.

  3. Override the values in the Executable file, Command line, and Working directory boxes in the Java Tab (Record and Run Settings Dialog Box) by defining the Java application details using the following variables:


    Variable Name


    Executable file


    The executable file or a batch file to open.

    Command line


    The command line to use to open the file.

    Working directory


    The folder to which the specified command line or executable file refers.

Use short paths in these commands if necessary. For example:

Micro Focus\UNIFIE~1\bin\JAVA_S~1\classes\jasmine.jar 

In this example, UFT is installed in the default installation folder (C drive, Program Files) on a Windows 7 computer. PROGRA~2 denotes the Program Files (x86) folder, which is the Program Files folder on 64-bit operating systems.

Got it!
Welcome to the help center for UFT One, formerly known as Unified Functional Testing. UFT One is part of the new Micro Focus UFT family of integrated functional testing solutions.