and its not working for me. I want to get a better solution than this. Thats what Im asking. I just want the highest value on future bars with ihighest? Is that possible and how?
int time = Time[0]+40*Period()*60; // 40 bars in futureint iB=iBarShift(NULL,NULL, time);
double fhval=High[iHighest(NULL,0,MODE_HIGH,40,iB)];
double flval=Low[iLowest(NULL,0,MODE_LOW,40,iB)];
Look I want something like this please?
40 bars in the future and the ihighest of that. And I just want this please..
The above I need to figure out the iBarShift and what bar it is. The above is not working.
So my question I can actually ask something different like. Can you help me correct iBarshift so that I can find the future bar number 40 bars in the future?
So my question I can actually ask something different like. Can you help me correct iBarshit so that I can find the future bar number 40 bars in the future?
RaptorUK:
Perhaps you should have read the whole thread . . .
1. You cannot use it to predict the future.
2. The original poster hasn't bother to post any debug information.
3. A simple query to ibarshift will tell him if the response is -1. If that is the case then there is no data available, and he cannot use it in the manner he intended.
CodeMonkey:
1. You cannot use it to predict the future.
Actually you can . . . make a copy of the symbol in question to an offline chart with a modified symbol name, now iBarshift() can be used from the Strategy Tester on the modified symbol to get information on bars in the future . . . the OP's issue is that he/she doesn't want to make any effort to solve his/her issue, he/she wants a two line code solution.
Ok but Im asking how to get the ihighest which means the highest price of 40 bars in the future but I have to do something like this.
and its not working for me. I want to get a better solution than this. Thats what Im asking. I just want the highest value on future bars with ihighest? Is that possible and how?
Look I want something like this please?
40 bars in the future and the ihighest of that. And I just want this please..
The above I need to figure out the iBarShift and what bar it is. The above is not working.
So my question I can actually ask something different like. Can you help me correct iBarshift so that I can find the future bar number 40 bars in the future?
Can you help me with that please?
So my question I can actually ask something different like. Can you help me correct iBarshit so that I can find the future bar number 40 bars in the future?
Can you help me with that please?
https://docs.mql4.com/series/ibarshift
iBarShift will return -1 if there is no data available.
There is sample code on the above page which explains how to use it.
https://docs.mql4.com/series/ibarshift
iBarShift will return -1 if there is no data available.
There is sample code on the above page which explans how to use it.
Perhaps you should have read the whole thread . . .
2. The original poster hasn't bother to post any debug information.
3. A simple query to ibarshift will tell him if the response is -1. If that is the case then there is no data available, and he cannot use it in the manner he intended.
1. You cannot use it to predict the future.
I just want to get this working on something Im working on.
I tried this one to get future time in strategy testing but Im getting zero on iB.
Anybody got a solution with src code please? It cant be that hard can it? I looked everywhere today for simple solution.
I just want to get this working on something Im working on.
I tried this one to get future time in strategy testing but Im getting zero on iB.