Skip to content

ChartFrame.TimeFrame

property · ChartFrame · cAlgo.API

DesktopCLICloud

Get / set frame chart timeframe.

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

TimeFrame TimeFrame {get; set;}
chartFrame.TimeFrame: TimeFrame

Returns TimeFrame

Examples

var chartFrame = ChartManager.AddChartFrame("EURUSD", TimeFrame.Hour);
chartFrame.TimeFrame = TimeFrame.Hour4;
Print("Chart time frame: {0}", chartFrame.TimeFrame);
chartFrame = api.ChartManager.AddChartFrame("EURUSD", TimeFrame.Hour)
chartFrame.TimeFrame = TimeFrame.Hour4
api.Print(f"Chart time frame: {chartFrame.TimeFrame}")