Highest since a specific time; iBarShift

Indicators coded by community members
Message
Author
kreisel
Posts: 3
Joined: Wed Apr 23, 2014 1:21 pm

Highest since a specific time; iBarShift

#1 Postby kreisel » Tue Mar 17, 2015 4:18 pm

Hello!

I want to get the Highest value since 12:30 of the day. In MQL it´s no problem to calculate the specific time and then using "BarShift" and "iHighest" to get the specific Bar.
But if I want to translate this to Delphi I get an error concerning iBarShift: "[Error] Strategie.dpr(268): Not enough actual parameters":

var
TimeHigh: TdateTime;
shift1: Integer;
iHi1: Integer;
xHigh1: Double;

TimeHigh:= iTime(Symbol,1440,0) + 12*60*60 + 30*60;
shift1 := iBarShift(Symbol,15,TimeHigh);
iHi1 := iHighest(Symbol,15,MODE_HIGH,shift1,0);
xHigh1 := iHigh(Symbol,15,iHi1);

Please, anybody can help me?
Thanks!

Stonev
Posts: 204
Joined: Thu Jan 28, 2010 2:20 pm

Re: Highest since a specific time; iBarShift

#2 Postby Stonev » Wed Mar 18, 2015 2:26 am

Hi,
try this:
iBarShift(Symbol,15,TimeHigh,false);
Coding & Converting


Return to “Indicators”

Who is online

Users browsing this forum: No registered users and 8 guests