Question for Target

Post Reply
Jonas
Posts: 11
Joined: 02 Feb 2014 09:43

Question for Target

Post by Jonas »

Hello community,

i have an issue with the setTargetPrice function.
The chart shows the green line of the target but doesn’t fullfill the target order. Is their anything i have to do before i can use a target stop in the future station.
Here is my code its very simple so i think the interface is the problem:

input $TargetLong(1,50,20);
input $TargetShort(1,50,20);

numeric i,zahl,verhaeltnis,verhaeltnis2;
bool Weg;

series Body_S,Candle_S,Body_H,Body_L,Renkofarbe;


series UK_Indi(Sentimentexpress.extraeinstieg2);

// -----------------------------------------------------
Calculation
// --------------------------

if(IsBarCompleted()) then
begin
if(UK_Indi[BarsSinceEntry()+1]>0) then
begin
if(MarketPosition()=1) then
begin
SetTargetPrice(EntryPrice()+($TargetLong/100));
end

if(MarketPosition()=-1) then
begin
SetTargetPrice(EntryPrice()-($TargetShort/100));
end
end

Thanks,
Jonas
Post Reply

Return to “WHS NANOTRADER - EXPRESS PROGRAMMING”