Backtest Mode Input variable
-
Good morning everyone,
I want to input variables to change between 3 input mode's.
Every tick
1minute bar ohlc
Openprice
My goal is to echif backtestresolds like in the live market.
Is this possible to implement and change the blocks accordingly and what happens with the higher timeframe indicators in the Code.
It would be wonderful if someone can help me. -
You will need a ENUM type variable to do that. I'm not an expert on that but I'm sure you will find many threads dedicated to that topic by selecting ENUM (capital letters) as keyword.
-
Thank you for your responding. I have found something that i would like to implement can i postet hear the link to it?
-
#property strict
enum ENUM_BAR_PROCESSING_METHOD
{
PROCESS_ALL_DELIVERED_TICKS, //Process All Delivered Ticks
ONLY_PROCESS_TICKS_FROM_NEW_M1_BAR, //Only Process Ticks From New M1 Bar
ONLY_PROCESS_TICKS_FROM_NEW_TRADE_TF_BAR //Only Process Ticks From New Bar in Trade TF
};//################
// Input Variables
//################input ENUM_TIMEFRAMES TradeTimeframe = PERIOD_M15; //Trading Timeframe
input ENUM_BAR_PROCESSING_METHOD BarProcessingMethod = ONLY_PROCESS_TICKS_FROM_NEW_M1_BAR; //EA Bar Processing Method -
because of this errors that i recive

-
@Alex-13
Your ENUM codes seems right. The problem may have happened somewhere else. See the error, it seems not related to your inputs code -
No,this are different errors.