Skip to content

FindAll Method (5)

FindAll (1 of 5)

Summary

Find all positions with this label.

Signature

1
public abstract Position[] FindAll(string label)

Parameters

Name Type Description
label string Label to search by

Return Value

Position[]

Declaring Type

cAlgo.API.Positions

Examples

1
 int totalPositions = Positions.Count;
1
 Position position =  Positions.Find("myLabel", Symbol, TradeType.Buy);
1
 Position[] positions = Positions.FindAll("myLabel", Symbol, TradeType.Buy);
1
 Positions.Opened += PositionsOnOpened;

FindAll (2 of 5)

Summary

Find all positions with this label and symbol name.

Signature

1
public abstract Position[] FindAll(string label, string symbolName)

Parameters

Name Type Description
label string Label to search by
symbolName string Symbol name to search by

Return Value

Position[]

Declaring Type

cAlgo.API.Positions

Examples

1
 int totalPositions = Positions.Count;
1
 Position position =  Positions.Find("myLabel", Symbol, TradeType.Buy);
1
 Position[] positions = Positions.FindAll("myLabel", Symbol, TradeType.Buy);
1
 Positions.Opened += PositionsOnOpened;

FindAll (3 of 5)

Summary

Finds all the positions of this label, symbol name and trade type.

Signature

1
public abstract Position[] FindAll(string label, string symbolName, TradeType tradeType)

Parameters

Name Type Description
label string Label to search by
symbolName string Symbol name to search by
tradeType TradeType Trade type to search by

Return Value

Position[]

Declaring Type

cAlgo.API.Positions

Examples

1
 int totalPositions = Positions.Count;
1
 Position position =  Positions.Find("myLabel", Symbol, TradeType.Buy);
1
 Position[] positions = Positions.FindAll("myLabel", Symbol, TradeType.Buy);
1
 Positions.Opened += PositionsOnOpened;

FindAll (4 of 5)

Signature

1
public abstract Position[] FindAll(string label, Symbol symbol)

Parameters

Name Type Description
label string
symbol Symbol

Return Value

Position[]

Declaring Type

cAlgo.API.Positions

FindAll (5 of 5)

Signature

1
public abstract Position[] FindAll(string label, Symbol symbol, TradeType tradeType)

Parameters

Name Type Description
label string
symbol Symbol
tradeType TradeType

Return Value

Position[]

Declaring Type

cAlgo.API.Positions


Last update: July 1, 2022

Comments