Skip to content

BacktestingCompletedEventArgs.Process

property · BacktestingCompletedEventArgs · cAlgo.API

DesktopCLICloud

Gets the backtesting process that has completed.

Environment behaviour

CLI — not supported. Available to plugins only, and plugins cannot run in the CLI.

Cloud — not supported. Available to plugins only, and plugins cannot run in the cloud.

Definition

public BacktestingProcess Process {get;}
backtestingCompletedEventArgs.Process: BacktestingProcess

Returns BacktestingProcess

Examples

protected override void OnStart()
{
    Backtesting.Completed += OnBacktestingCompleted;
}

private void OnBacktestingCompleted(BacktestingCompletedEventArgs args)
{
    Print("Process completed: {0}, error: {1}", args.Process.IsCompleted, args.Process.BacktestingError);
}
def on_start(self):
    api.Backtesting.Completed += self.on_backtesting_completed

def on_backtesting_completed(self, args):
    api.Print(f"Process completed: {args.Process.IsCompleted}, error: {args.Process.BacktestingError}")