# TimeCurrent

Returns the current time.

## Syntax

```typescript
TimeCurrent(): FTODate
```

## Return Value

Returns an [`FTODate`](https://fto-2.gitbook.io/fto-strategies-docs/strategies/fto-date) object representing the current time.

## Description

The `TimeCurrent` method returns the current time as an [`FTODate`](https://fto-2.gitbook.io/fto-strategies-docs/strategies/fto-date) object. This time represents the timestamp of the last processed tick in the project. The returned [`FTODate`](https://fto-2.gitbook.io/fto-strategies-docs/strategies/fto-date) object provides various methods for date and time manipulation.

## Example

```typescript
// Get current time
const currentTime = this.api.TimeCurrent();

// Display current time components
console.log(
  `Date: ${currentTime.yearOf()}.${currentTime.monthOf()}.${currentTime.dayOfMonth()}`
);
console.log(
  `Time: ${currentTime.hour()}:${currentTime.minute()}:${currentTime.second()}`
);

// Get timestamp in milliseconds
const timestamp = currentTime.getTime();
console.log(`Timestamp: ${timestamp}`);

// Format the date
console.log(`Formatted date: ${currentTime.toString()}`);

// Check if it's weekend
const dayOfWeek = currentTime.dayOfWeek();
const isWeekend = dayOfWeek === 0 || dayOfWeek === 6;
console.log(`Is weekend: ${isWeekend}`);
```
