Rank: Member
Groups: Registered, Registered Users Joined: 6/29/2007(UTC) Posts: 19
|
Good evening everyone,
I'm trying to use the forum.latch function for the 1st time. The "Long Entry" and "Short Entry" generate the expected signals. Both exit signals however fail to print on a chart. Here is the code I'm using:
{ENTER LONG}
LE:= OscP(10,30,S,$)>0;
LX:= OscP(10,30,S,$) < Ref(OscP(10,30,S,$),-1);
SE:= OscP(10,30,S,$)<0;
SX:= OscP(10,30,S,$) > Ref(OscP(10,30,S,$),-1);
B:= ExtFml(“forum.Latch",LE,LX,SE,SX);
B = 1 AND Ref(B,-1) <> 1
{ENTER SHORT}
LE:= OscP(10,30,S,$)>0;
LX:= OscP(10,30,S,$) < Ref(OscP(10,30,S,$),-1);
SE:= OscP(10,30,S,$)<0;
SX:= OscP(10,30,S,$) > Ref(OscP(10,30,S,$),-1);
B:= ExtFml(“forum.Latch",LE,LX,SE,SX);
B = -1 AND Ref(B,-1) <> -1
{EXIT LONG}
LE:= OscP(10,30,S,$)>0;
LX:= OscP(10,30,S,$) < Ref(OscP(10,30,S,$),-1);
SE:= OscP(10,30,S,$)<0;
SX:= OscP(10,30,S,$) > Ref(OscP(10,30,S,$),-1);
B:= ExtFml(“forum.Latch",LE,LX,SE,SX);
B = 0 AND Ref(B,-1) = 1
{EXIT SHORT}
LE:= OscP(10,30,S,$)>0;
LX:= OscP(10,30,S,$) < Ref(OscP(10,30,S,$),-1);
SE:= OscP(10,30,S,$)<0;
SX:= OscP(10,30,S,$) > Ref(OscP(10,30,S,$),-1);
B:= ExtFml(“forum.Latch",LE,LX,SE,SX);
B = 0 AND Ref(B,-1) = -1
Any idea why the entry signals print, but the exits do not?
|