Skip to content

TradeWatchTabAttachedEventArgs.TradeWatchTab

property · TradeWatchTabAttachedEventArgs · cAlgo.API

DesktopCLICloud

Attached tab.

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 TradeWatchTab TradeWatchTab {get;}
tradeWatchTabAttachedEventArgs.TradeWatchTab: TradeWatchTab

Returns TradeWatchTab

Examples

protected override void OnStart()
{
    var tab = TradeWatch.AddTab("My Tab");
    tab.Attached += OnTradeWatchTabAttached;
}

private void OnTradeWatchTabAttached(TradeWatchTabAttachedEventArgs args)
{
    Print("Tab {0} attached at index {1}", args.TradeWatchTab.Id, args.TradeWatchTab.Index);
}
def on_start(self):
    tab = api.TradeWatch.AddTab("My Tab")
    tab.Attached += self.on_trade_watch_tab_attached

def on_trade_watch_tab_attached(self, args):
    api.Print(f"Tab {args.TradeWatchTab.Id} attached at index {args.TradeWatchTab.Index}")