how to check if last price is the highest on current bar
tenlau:
Hello,
I am new to MQL5 programming.
I want to check if the last price (from MqlTick structure) is the highest on the current timeframe bar. I coded something like:
if (last_price.last=mrate[0].high) and I receive an warning "expression not boolean", which is very correct, but I have no other ideea how to code this.
Try
if (last_price.last == mrate[0].high)
Thank you, it works!
Hello,
I am new to MQL5 programming.
I want to check if the last price (from MqlTick structure) is the highest on the current timeframe bar. I coded something like:
if (last_price.last=mrate[0].high) and I receive an warning "expression not boolean", which is very correct, but I have no other ideea how to code this.