---
id: "T:cAlgo.API.TicksTickEventArgs"
kind: "class"
namespace: "cAlgo.API"
url: "https://help.ctrader.com/ctrader-algo/references/EventArgs/TicksTickEventArgs/"
---

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

# TicksTickEventArgs (class)

Provides data for the tick event.

Environments: Desktop supported · CLI supported · Cloud supported.

## Definition

```csharp
public class TicksTickEventArgs
```

## Examples

C#:

```csharp
using cAlgo.API;
using cAlgo.API.Internals;

namespace cAlgo
{
    // This sample indicator shows how to use TicksTickEventArgs
    public partial class TicksTickEventArgsSample : Indicator
    {
        private Ticks _ticks;

        protected override void Initialize()
        {
            // Getting a symbol ticks data
            _ticks = MarketData.GetTicks(InputSymbolName);
            // Subscribing to upcoming ticks
            _ticks.Tick += OnTicksTick;
        }

        private void OnTicksTick(TicksTickEventArgs obj)
        {
            // Printing Last tick inside Ticks collection
            Print(obj.Ticks.LastTick);
        }

        public override void Calculate(int index)
        {
        }
    }
}
```

Python:

```python
import clr
clr.AddReference("cAlgo.API")

from cAlgo.API import *

class Test():
    def initialize(self):
        self.ticks = api.MarketData.GetTicks(api.InputSymbolName)
        # Subscribing to upcoming ticks
        self.ticks.Tick += self.on_ticks_tick

    def on_ticks_tick(self, args):
        # Printing Last tick inside Ticks collection
        print(args.Ticks.LastTick)
```

config.json:

```json
{
  "AccessRights": "None",
  "TimeZone": "UTC",
  "IsOverlay": true,
  "Parameters": [
    {
      "Name": "InputSymbolName",
      "DisplayName": "Symbol Name",
      "Type": "String",
      "DefaultValue": "EURUSD"
    }
  ]
}
```

## Properties

- `public Ticks Ticks {get;}` — Gets the Ticks data. [details](https://help.ctrader.com/ctrader-algo/references/EventArgs/TicksTickEventArgs/Ticks/index.md)

