How to set the close price of bar[2] as stoploss price when opening an order?

 
I designed my EA based on the M5 chart. I'd like to set the close price of bar[2] of the M15 CHART as the stoploss price when opening a position. How can I quote the price? Thanks!
 

double stopLoss;

stopLoss = iClose(Symbol(), 15, 2);

 
Many thanks, phy!