I was thinking of using the profit or loss of the last trade as one of the conditions for buy and sell signals. I found out a way to get the profit/loss by using this function:
and storing it in an array with 2 locations, one to store the past account balance, and one to store the present balance. Then subtract the past account balance from the present account balance to get the profit/loss. Afterwards, delete the past balance, move the present balance to the first location and wait for the next balance to place in the second location... and repeat the process..
It really sounds cumbersome and I was thinking if there is a function available so that the last profit/loss can be retrieved without going through the process above?
Thanks in advance!:D
Read about HistoryDealGetDouble().
Thanks for pointing me in the right direction!