PreviousNext
Help > Tutorial: General Operation > Operating from the Command Line
Operating from the Command Line

When the command line to execute the program includes a project file (FPZip or FPProj) and the \b parameter, Forecast Pro will read the project, 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 desire a “hands-off” approach.

If you are using a Collaborator license, this lesson requires a Forecaster license.

In this lesson, we will first use Forecast Pro interactively to create a project file. We will then exit the program and create forecasts for the project via the command line.

Start Forecast Pro and open a New Project. On the Home tab, select Options to open the Options dialog box and then click on the Command Line tab.

The Project Components to Apply section allows you to control how the forecasts are generated when the project is run from the command line.

The Modifiers drop-down allows you to specify how modifiers are applied in the command-line mode. Click on the drop-down, and you will see that there are four options: None, Project (default), Data Source and Project and Data Source. If None is selected, expert selection will be used for all items. If Project is selected, Forecast Pro will apply modifiers as specified in the Project’s Navigator. If Data Source is selected, Forecast Pro will consider only modifiers specified in the Data Manager. If Project and Data Source is specified, Forecast Pro will apply modifiers specified in the Navigator for items that do not have a modifier in the Data Source and apply Data Source modifiers wherever specified. (Note that if modifiers are present both on the Navigator and in the Data Source, the Data Source is used.)

The Overrides drop-down has the same options and functionality as the Modifiers drop-down, described above.

If Settings is selected, the command-line run will use all of the settings associated with the project (e.g., all settings in the Settings dialog box, numeric output formatting, etc.). If this option is not selected, the default settings (i.e., the settings that have been saved as the defaults for use with new projects) will be used when running from the command line.

The Output Files section allows you to specify the output files to generate when the project is run from the command line. The format and content of these files will match the current project’s settings.

Make sure your settings match the ones above. Click the OK button to save your selections.

Click the Data Manager icon on the Home tab to call up the Data Manager.

Click the Add drop-down on the Historic Data row, select Excel and select 123 Bakery – Historic Data.xlsx. Click the Exit button to exit the data manager. A warning will be displayed stating that “one or more data sources have not been applied”, click OK to exit the Data Manager without reading the data.

Select File and then Save to save the project. Name the project “Test”. Exit Forecast Pro.

We will now run the project from the command line.

You can execute a command line using the Search box on the Windows Start Menu or using the Windows Run command. Execute the program including Test.FPZip as a parameter followed by “ /b”. If you installed Forecast Pro into a directory named “C:\Program Files\Forecast Pro\Forecast Pro TRAC v7 64-bit” the command line should read (including the quotation marks):

"C:\Program Files\Forecast Pro\Forecast Pro TRAC v7 64-bit\ForecastProTRAC.exe" Test.FPZip /b

After issuing the command, the program will read in the historic data, calculate the forecasts and create all of the requested output files. Examine your output directory to confirm the files were created.

For more detailed information regarding command-line operation consult Command Line Operation in the Forecast Pro Reference Manual.

This concludes the Operating from the Command Line lesson.




PreviousNext