Forums ProRealTime English forum ProOrder support How to define the bar Index correctly? Reply To: How to define the bar Index correctly?

#32072

Hi Bard

If you put the code up as code (not an image) then I could run it and check it out better.

But in the meantime Line  23 needs to read

Sell at Market (not sell 10 shares at market)

Whenever I’ve mistakenly put Sell * shares as an Exit I get an error message that it is not allowed? But I could check this out if I could run the code.

Also Line 22 should read (bar index – tradeindex = 3) … all within brackets (you have = 3 outside the brackets).

Apart from the above errors then as far as I can see the Trade should exit after 3 bars, but running your code on my Platform is the easiest way for me to get involved?

GraHal

1 user thanked author for this post.