View Single Post
  #1 (permalink)  
Old 05-07-2006, 06:56 AM
Gavner Gavner is offline
Junior Member
 
Join Date: Apr 2006
Location: Boston
Posts: 8
Gavner is on a distinguished road
Need some simple help with an EA...

Hello all-
I'm new to programming and this forum, and yesterday I wrote a simple EA based on the Parabolic SAR (Buy when it's below current price, sell when it's above). I have already written trailing stops into the program, but currently it initiates a new order in the same direction that I just closed something with the trailing stop (since the SAR hasn't switched over yet). I don't want this; if the last closed trade was a sell, I want the program to wait for appropriate conditions (SAR below price) to initiate a buy, and vice versa. I'm sure there's a simple way to do this, but I can't figure it out .
Thanks a bunch in advance,
Gavner
Attached Files
File Type: mq4 SAR Cross.mq4 (4.4 KB, 41 views)
Reply With Quote