---
id: "P:cAlgo.API.TimeSeries.LastValue"
kind: "property"
type: "T:cAlgo.API.TimeSeries"
url: "https://help.ctrader.com/ctrader-algo/references/Collections/DataSeries/TimeSeries/LastValue/"
---

> Documentation index for agents: https://help.ctrader.com/ctrader-algo/llms.txt · machine index: https://help.ctrader.com/ctrader-algo/api.json

# TimeSeries.LastValue

Member of [TimeSeries](https://help.ctrader.com/ctrader-algo/references/Collections/DataSeries/TimeSeries/index.md).

## LastValue

Gets the last value of this time series.

Environments: Desktop supported · CLI supported · Cloud supported.

C#:

```csharp
DateTime LastValue {get;}
```

Python:

```python
timeSeries.LastValue: DateTime
```

### Returns

`DateTime` — 

### Examples

C#:

```csharp
var openTime = Bars.OpenTimes.LastValue;
Print("The current bar opened at {0}", openTime);
```

Python:

```python
openTime = api.Bars.OpenTimes.LastValue
api.Print(f"The current bar opened at {openTime}")
```

