News functions are mostly used for accessing the news log which logs incoming news events from the data provider.


Sections


Functions

Function Details


Functions


Name

Description

NewsAddMessage(int, string, string, C_MessageType)

Adds a message to the news log.

string NewsMessage(int)

Gets the message text of a specified news message.

int NewsMessageCount()

Gets the number of messages in the log.

long NewsMessageDateTime(int)

Gets the date/time of a specified news message.

int NewsMessageSymbolIndex(int)

Gets the symbol index of a specified news message.

string NewsMessageTitle(int)

Gets the title of a specified news message.

C_MessageType NewsMessageType(int)

Gets the message type of a specified news message.


Function Details


NewsAddMessage(int symbolIndex, string title, string message, C_MessageType type)

Adds a message to the news log.


Parameters


Type

Identifier

Description

int

symbolIndex

The symbol index

string

title

The message title

string

message

The message

C_MessageType

type

The message type (View Options)


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, TradingStrategy


string NewsMessage(int index)

Gets the message text of a specified news message.


Returns


The message text of the specified news message.


Parameters


Type

Identifier

Description

int

index

The message index


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, TradingStrategy


int NewsMessageCount()

Gets the number of messages in the log.


Returns


The number of messages in the log.


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, TradingStrategy


long NewsMessageDateTime(int index)

Gets the date/time of a specified news message.


Returns


The date/time of the specified news message.


Parameters


Type

Identifier

Description

int

index

The message index


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, TradingStrategy


int NewsMessageSymbolIndex(int index)

Gets the symbol index of a specified news message.


Returns


The symbol index of the specified news message.


Parameters


Type

Identifier

Description

int

index

The message index


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, TradingStrategy


string NewsMessageTitle(int index)

Gets the title of a specified news message.


Returns


The title of the specified news message.


Parameters


Type

Identifier

Description

int

index

The message index


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, TradingStrategy


C_MessageType NewsMessageType(int index)

Gets the message type of a specified news message.


Returns


The message type of the specified news message. (View Options)


Parameters


Type

Identifier

Description

int

index

The message index


Scripts


Alert, TradeManagementStrategy, MultiSymbolTradingStrategy, Screener, TradingStrategy