![]()
The CSV File Reader Utility executes commands received by text files of type CSV (Comma Separated Values). This type of Utility is ideal for those who process signals in other applications, and want to manage signals and positions in Metatrader.
The Utility also has some extra functions, such as the possibility of Filtering Commands with Magic Number , and also ignoring commands for a symbol that already has open orders or positions.
The available Commands are:Mandatory columns: Signal, Symbol, Volume
- BuyMarket
Optional columns: StopLoss, TakeProfit
- SellMarket
Mandatory columns: Signal, Symbol, Volume
Optional columns: StopLoss, TakeProfit
- BuyLimit
Mandatory columns: Signal, Symbol, Volume, Price
Optional columns: StopLoss, TakeProfit
- SellLimit
Mandatory columns: Signal, Symbol, Volume, Price
Optional columns: StopLoss, TakeProfit
- BuyStop
Mandatory columns: Signal, Symbol, Volume, Price
Optional columns: StopLoss, TakeProfit
- SellStop
Mandatory columns: Signal, Symbol, Volume, Price
Optional columns: StopLoss, TakeProfit
- ChangeStops
Mandatory columns: Signal, Symbol; StopLoss and TakeProfit. You can omit TakeProfit or StopLoss, but can't omit both columns
- ClosePosition
Mandatory columns: Signal, Symbol
The Utility Input Parameters are:
- File Name: the name of the file with the commands that the Utility should execute. The Utility will look for the file in the Metatrader Files folder.
- Delimiter: CSV file can be separated by ',' (comma) or ';' (semicolon).
- Symbol Column Name: the name of the column that contains the Symbol to be traded.
- Signal Column Name: the name of the column that the command is being executed.
- Volume Column Name: the name of the column containing the Volume to be traded (mandatory only if the command is of type BuyMarket, BuyLimit, BuyStop, SellMarket, SellLimit or SellStop).
- Price Column Name: the name of the column containing the Price. Only required if the command is BuyLimit, BuyStop, SellLimit or SellStop.
- Stop Loss Column Name: the name of the column with the Stop Loss value. Optional parameter.
- Take Profit Column Name: the name of the column with the Take Profit value. Optional parameter.
- Ignore if there is already an Open Order: if the Magic Number parameter is disabled and this parameter is true, then it checks if there is already an Order of the same Symbol, if it exists, it ignores the order. If the Magic Number is greater than zero, then consider the Symbol and Magic Number.
- Ignore if it already has an Open Position: if the Magic Number parameter is disabled and this parameter is true, then it checks if there is already a Position of the same Symbol, if it exists, it ignores the order. If the Magic Number is greater than zero, then consider the Symbol and Magic Number.
- Time Zone to Use: This parameter will only be useful if the Time Limit parameters are activated (start time to allow orders. end time to not allow more orders).
- Execution Mode: there are two configuration types for the Utility execution: 1) Every Tick and 2) Based on Timer.
- Chronometer Frequency: only used if the execution type is Based on Timer. Represents the time in seconds (frequency) that the Utility must search for a new command file.
- The time parameters that allow the operation of file reading from an Initial time configured in the input parameters.
- The time parameters that allow the operation of reading files from an End time configured in the input parameters.
Orders comment.
- Magic Number: If Magic Number is zero, then it's considered disabled.