TJ,
Thanks, I just on't knwo that there is afunction call Time_S.
Well, I have just switched to use MC for months after using Metastock. I have tried to code the above idea, but have not tested in realtime. Please comment if there is any error.
[IntrabarOrderGeneration = True];
Inputs: TT(161445);
Vars: TExit(0);
TExit=Iff(Time_S>=TT,1,0);
If TExit=1 Then Sell ("LX") at Next bar at Close limit;
If TExit=1 Then Buy to Cover ("SX") at Next bar at Close limit;
I have not added the respective MarketPosition = 1 (or -1) for Sell and Buy to Cover, as I have tested for end of bar signal, that seems working without them, don't know why.
BTY, I've sent you a PM a long time ago. please check.
Sa