| stevehopwoodforex.com https://www.stevehopwoodforex.com/phpBB3/ Print view |
|
| Please Help a Novice stop a For Loop https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?t=5579 |
Page 1 of 2 |
| Author: | burnrubber75 [ Sun Dec 02, 2018 10:29 am ] |
| Post subject: | Please Help a Novice stop a For Loop |
I am trying to use the code attached to open 2 Pending Orders, however once SL or TP has been hit I don't want it to open another order until I drop the EA back on the chart if this is possible Code: Select all P.S Also do you now as a new member I can't see or download any attachments i.e Scripts or EA's? |
|
| Author: | SteveHopwood [ Sun Dec 02, 2018 2:17 pm ] |
| Post subject: | Please Help a Novice stop a For Loop |
The easiest way is to the the EA to remove itself when it detects a trade has closed. Declare a couple more variables to go with int t: bool RemoveExpert = false; int t = 0, oldt = 0; Pop this snippet at the top of OnStart() Code: Select all Code: Select all |
|
| Author: | burnrubber75 [ Tue Dec 04, 2018 12:06 am ] |
| Post subject: | Please Help a Novice stop a For Loop |
Excellent Thanks so much |
|
| Author: | burnrubber75 [ Tue Dec 04, 2018 12:27 am ] |
| Post subject: | Please Help a Novice stop a For Loop |
Steve thanks that works how would I code it to once an order has kicked in to delete the other pending order and then stop the EA Thanks in advance. |
|
| Author: | burnrubber75 [ Tue Dec 04, 2018 2:33 am ] |
| Post subject: | Please Help a Novice stop a For Loop |
Sorted, put the code in wrong block Thanks again for your help! |
|
| Author: | SteveHopwood [ Tue Dec 04, 2018 10:16 pm ] |
| Post subject: | Please Help a Novice stop a For Loop |
Good to see you delving under the bonnet of this stuff. Really good to see you sorting out a problem for yourself. This is the best way to learn. |
|
| Author: | burnrubber75 [ Fri Dec 07, 2018 4:38 am ] |
| Post subject: | Please Help a Novice stop a For Loop |
Please can you help me add high & low of last n candles, then I need to add the pending orders x pips from those high/low prices? Manage to sort of code it to place a line across the candles Code: Select all |
|
| Author: | SteveHopwood [ Fri Dec 07, 2018 9:03 pm ] |
| Post subject: | Please Help a Novice stop a For Loop |
Indicators cannot place trades. |
|
| Author: | burnrubber75 [ Tue Dec 11, 2018 9:03 am ] |
| Post subject: | Please Help a Novice stop a For Loop |
Ok knew that, is it possible to add this to an EA to get it to work with the 2 Pending Orders EA you helped me with? Thanks
|
|
| Author: | SteveHopwood [ Tue Dec 11, 2018 9:50 am ] |
| Post subject: | Please Help a Novice stop a For Loop |
Yes. Study any one of my shells for an example of how to use iHighest and to find functions that will draw lines for you. Shells are found at http://www.stevehopwoodforex.com/phpBB3 ... p=803#p803 |
|
| All times are UTC | Page 1 of 2 |
|
Powered by phpBB® Forum Software © phpBB Limited |
|