IBM Support

How to call a Rational Functional Tester script from a regular Java project

Technote (FAQ)


How can you call an IBM® Rational® Functional Tester (RFT) script from a regular Java™ project?


You want to add functions to your non-RFT Java project and re-use RFT code.


You cannot call an RFT class like you would do for any Java program.

An RFT project differs from a regular Java program. Therefore it is not enough to call a class like you would do for any Java program. Using callscript does not call the RFT script.

You can try to call the RFT script from a Java project with the following steps.

    1. Create a simple Java project.

    2. Create a sample class. Below is the code for this class.

    3. Add the rational_ft.jar file in the Java project classpath, the Java build path. The JAR's default location is:

      C:\Program Files\IBM\SDP70\FunctionalTester\bin

    4. Modify the location of your RFT script. Now you can call an RFT script from this Java class.


All source code and/or binaries attached to this document are referred to here as "the Program". IBM is not providing program services of any kind for the Program. IBM is providing the Program on an "AS IS" basis without warranty of any kind. IBM WILL NOT BE LIABLE FOR ANY ACTUAL, DIRECT, SPECIAL, INCIDENTAL, OR INDIRECT DAMAGES OR FOR ANY ECONOMIC CONSEQUENTIAL DAMAGES (INCLUDING LOST PROFITS OR SAVINGS), EVEN IF IBM, OR ITS RESELLER, HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

public class ExternalClassforRFT {

public static void main(String[] args) {
String rftplaybackArgs[] = new String[]{"-datastore", "C:\\Testmanager\\RemoteTesting\\DataPoolTesting", "-playback", "DataPoolTest"};

}catch (Exception e){}

System.out.println("I got .. + " + rftplaybackArgs.toString());
// TODO Auto-generated method stub

Document information

More support for: Rational Functional Tester

Software version: 6.1,, 6.1.1,, 7.0,,, 7.0.1,,,, 8.0,,,, 8.1,,,, 8.1.1,,,, 8.2,,, 8.2.1,, 8.2.2

Operating system(s): Windows

Reference #: 1306251

Modified date: 07 July 2008

Translate this page: