ricardo.ballinas
ricardo.ballinas 19 Sep 2020, 08:50
firemyst said:
An issue you have is with the statements: LastResult.Position.GrossProfit Let's say you have 3 positions #1, #2, #3. the LastResult is Position #3. However, your system could then close position #3. so the next OnTick it checks the LastResult.Position, it no longer exists (since it was closed), thus you have a null reference.
An issue you have is with the statements:
LastResult.Position.GrossProfit
Let's say you have 3 positions #1, #2, #3.
the LastResult is Position #3.
However, your system could then close position #3.
so the next OnTick it checks the LastResult.Position, it no longer exists (since it was closed), thus you have a null reference.
Thanks a lot bro!!! it worked!!!
ricardo.ballinas
19 Sep 2020, 08:50
RE:
firemyst said:
Thanks a lot bro!!! it worked!!!
@ricardo.ballinas