I need one bug removed from an otherwise functional EA.
The EA must only have one order open at a time, which is usually the case.
However, when the EA is removed from the chart, then attached to the chart again next time an order is opened it goes into a loop and opens orders continuously until all margin is used up.
Please fix the EA so that the program never opens repeat orders, and please briefly check and test the code to ensure that only one order can ever be open at one time. This is a quick fix, estimate and hour or two, thanks.