Skip to content

Position.LastUpdateTime

property · Position · cAlgo.API

DesktopCLICloud

Gets the time when a position was last updated. The timezone used is set in the algorithm class attribute.

Definition

DateTime? LastUpdateTime {get;}
position.LastUpdateTime: DateTime | None

Returns DateTime?

Examples

var position = Positions.Find("myLabel");
if (position != null && position.LastUpdateTime.HasValue)
    Print("Last updated at {0}", position.LastUpdateTime.Value);
position = api.Positions.Find("myLabel")
if position is not None and position.LastUpdateTime is not None:
    api.Print(f"Last updated at {position.LastUpdateTime}")