Ea closing at certain shift in line indicator

 
Hi all, I’ve tried to create EA based on ichimoku indi. I want to use the chikou Span (the lagging price line) as take profit. The idea is when the chikou span touches the bar then close the order. 

My code for the take profit is like this:

double takeProfitPrice  = 
    //chikou span line;
...
orderId                 = OrderSend(Symbol(),OP_BUY,lotSize,Ask,0,stopLossPrice,takeProfitPrice,"Weak BUY",magicNumberStrong);

I know that this is wrong because the take profit wouldn’t be trigger at all, it is happened because the chikou span line is shifted 26 bars and not on the current bar. What I want is when the chikou span that is shifted 26 bars hit the bar than EA will close the trade at the current bar. Anyone has the logic how to do that?