ChartRobots.RobotRemoved
event · ChartRobots · cAlgo.API
DesktopCLICloud
Occurs when a Robot is removed from a chart.
Environment behaviour
Cloud — not supported. Always empty: Count is 0, Add returns null, Remove returns false, and the events never fire.
Definition
event Action<ChartRobotRemovedEventArgs> RobotRemoved;
api.ChartRobots.RobotRemoved += handler # handler(obj: ChartRobotRemovedEventArgs)
Examples
protected override void OnStart()
{
ChartRobots.RobotRemoved += OnRobotRemoved;
}
private void OnRobotRemoved(ChartRobotRemovedEventArgs args)
{
Print("cBot removed: {0}", args.Robot.Name);
}
def on_start(self):
api.ChartRobots.RobotRemoved += self.on_robot_removed
def on_robot_removed(self, args):
api.Print(f"cBot removed: {args.Robot.Name}")