You can run Forecast Pro noninteractively via Command Line. When the command line to execute the program includes a project filename (*.FPZip or .FPProj if the project is unzipped) and the /b parameter, Forecast Pro will read in the data, create the forecasts, save all output files and then exit. This feature is particularly useful when you are integrating forecasting with other software systems and need a “hands-off” approach.
To run Forecast Pro automatically, follow these two steps.
1.) Prepare a valid project and place it in your project directory. The easiest way to prepare this file is to use Forecast Pro interactively to define all desired project settings, historic data, output formats and (optionally) forecast modifiers and overrides, and then save the project using use File>Save.
Alternatively, you can generate the file externally, but this will require understanding the project file and the (optional) corresponding db file formats.
2.) Run the command “ForecastProTRAC [Project Name] /b [options…]”. For example,
“C:\Program Files\Forecast Pro\Forecast Pro TRAC v8\ForecastProTRAC.exe” Test.FPZip /b
runs the program located in “C:\Program Files\Forecast Pro\Forecast Pro v7” for a project named Test.FPZip. The project should be in your current project directory. The “/b” parameter is used to indicate that you wish to run in command-line (batch) mode.
You can issue the command in any number of ways, including:
Select Run from the Start menu and issue the command from there.
Set up a shortcut to issue the command.
Issue the command from within a different application using a system call.
The Command Line tab of the Settings>Options dialog box allows you to specify several key command line forecasting options and the output files to save in command-line mode. This tab’s functionality was fully described The Command Line Tab.
Command line options include the following:
/LAYOUT=[Layout name] causes the program to load the indicated layout prior to generating any output files. If the layout is not found, then the program continues using its current settings.
/NOSAVE causes the program to forego re-saving the project at the end of command-line execution, regardless of the actual project setting (Settings > Options > Command Line > Project). The latter checkbox setting is respected if /NOSAVE is omitted.
/SAVEAS=[filename] allows specifying a new filename for the project file
/NOFORECAST the program simply loads the project, assuming it’s in a forecast and reconciled state, and generates the output.
/TITLE=[file title to use for output files] causes the program to replace the project name, e.g. “Project01”, with whatever is specified by the User here to build the output file names. For example /TITLE=Bookmark_1 would result in output files named accordingly, e.g., !Bookmark_1 Exceptions Report.xlsx. This setting is also applied to the ODBC output table, overriding any previous project setting. In the latter case, the User is advised to use a /TITLE value that complies with SQL naming conventions (e.g., no spaces).
/OUTPUTDIR=[path to a folder] allows specifying the folder where output files are saved regardless of the project setting.
/PLOG and /ELOG will force the program to generate project and error log files, respectively. This overrides the corresponding settings in the INI file and in the project definition. If a file title is specified using /TITLE=[…], it will be applied to the log file(s).
/PWD=[project password] allows the command line execution of projects that contain a password (TRAC version 22.214.171.124 and later).
/MODE=[XLSX or CSV or XLS] allows specifying a data mode other than XLSX for the Item, Exceptions, Outliers, and Overrides reports (TRAC version 126.96.36.199 and later).
/SCOPE=# allows specifying the scoping settings to use when exporting report(s) and will override the selection on the Export tab. Allowable values are (1) Current Display, (2) All Items, and (3) Hot List.
The following options allow the User to force the program to output the corresponding outputs/reports, even if they are unchecked within the project settings.
/OUTPUT – forces export of the Numeric Output regardless of the project setting.
/ITEM – forces export of the Item Report regardless of the project setting.
/EXCEPT# – forces export of the indicated Exception Report regardless of the project setting (TRAC-only), corresponding to the (1) Forecast vs. History, (2) Forecast vs. Archive, (3) Forecast Accuracy, (4) Waterfall, (5) Custom and (6) Global FVA . For example, /EXCEPT3 outputs the Forecast Accuracy report.
/OUTLIER – forces export of the Outlier Report regardless of the project setting.
/QUERY – forces export of any previously checked Query Report(s) regardless of the project setting.
If there are spaces in the pathname you must include quotation marks as illustrated in the example above.