|
How to stop strategy? |
Korc
|
Post subject: How to stop strategy? |
Post rating: 0
|
Posted: Mon 03 Aug, 2015, 12:02
|
|
User rating: 0
Joined: Thu 16 Jul, 2015, 14:55 Posts: 17 Location: PolandPoland
|
Hi,
Help needed. How to stop strategy in case where defined price or pips quantity has been reached? The problem is, because when Take Profit was defined - posiotion has been closed an in the same time the next one is oppeded on the same price level
|
|
|
|
 |
amine_chourou
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Wed 05 Aug, 2015, 12:13
|
|
Visual JForex expert at Dukascopy |  |
User rating: 288
Joined: Thu 18 Apr, 2013, 09:26 Posts: 1496 Location: Switzerland, Geneva
|
Hi,
Depending on your strategy structure, you need to use the P&L in pips or in USD in an IF block and once the target is reached you stop the strategy using "Stop Strategy" block.
Cheers
|
|
|
|
 |
Korc
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Wed 05 Aug, 2015, 15:55
|
|
User rating: 0
Joined: Thu 16 Jul, 2015, 14:55 Posts: 17 Location: PolandPoland
|
Hi again, I did it, but Stop Strategy doesn't work. Where is my mistake? I will appreciate your solution/help as appendix. Regards
Attachments: |
Strat_EURUSDwithStop.vfs [22.98 KiB]
Downloaded 665 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
 |
jlongo
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Mon 10 Aug, 2015, 15:05
|
|
User rating: 94
Joined: Mon 06 Feb, 2012, 12:22 Posts: 357 Location: Portugal, Castelo Branco
|
Hi
Your strategy do not make sense at all...
Lets see... - tick received -if you do not have orders (open/pending) with a total of 1 million continue to next block... -open a pending buy with 0.001 millions at 1.095...(till now with this code it will open 1000 pending orders one at each received tick if price do not reach this price value, or/and filled orders till 1m in orders amount is reached) - next you check at order fill if last trade event has 15 pips profit - that means last order filled (you are trying to open pending order that will be filled later and not executed on this block or the order will be filled right at the block) - if you have on last trade event a profit on the trade referenced by the event greater than 15 pips, stop the strategy... usualy last trade filled (if no other event occurs between ticks) it will unlikely to have 15 pips in profit (not impossible at news but hard).
Sorry for my english if not clear... Regards JL
|
|
|
|
 |
Korc
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Wed 12 Aug, 2015, 08:42
|
|
User rating: 0
Joined: Thu 16 Jul, 2015, 14:55 Posts: 17 Location: PolandPoland
|
Hi, Thanks for your advices Yes, you are right, next orders will be open after previous opened order is closed. Now, for higher safe I need to close strategy when defined by me in PIPs or price level will be reached. Show, how and where attach StopStrategy Block. Thanks a lot
|
|
|
|
 |
jlongo
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Wed 12 Aug, 2015, 09:39
|
|
User rating: 94
Joined: Mon 06 Feb, 2012, 12:22 Posts: 357 Location: Portugal, Castelo Branco
|
Hi
With only that blocks and taking in consideration that blocks can open many orders, the only way i see it's to close all orders at predefined price level and stop the strategy. Bellow example where all orders get closed and strategy stoped if price gets greater than 1.0970.
Regards
JL
Attachments: |
Strat_EURUSDwithStop1.vfs [30.28 KiB]
Downloaded 563 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
 |
Korc
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Wed 12 Aug, 2015, 13:09
|
|
User rating: 0
Joined: Thu 16 Jul, 2015, 14:55 Posts: 17 Location: PolandPoland
|
You are great! Thank you very much. It finaly works
|
|
|
|
 |
Korc
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Wed 12 Aug, 2015, 18:11
|
|
User rating: 0
Joined: Thu 16 Jul, 2015, 14:55 Posts: 17 Location: PolandPoland
|
Hi, I appreciate your suggestions about many orders, that can be opened in my strategy, but I still didn't find solution. Look at this strategy; testing it on Visual JForex strategy works properly, it's mean that one, and only one order is opened when predefined open price is met. The next one will be opened only when first opened position is closed in Stop Loss point. If price doesn't met SL, then order stay opened until end of defined period or Stop Strategy point. The same strategy opened on DEMO opens tens or hundreds position. Can you repair my strategy. I need only that strategy will be working the same way on DEMO and LIVE account, like on Visual JForex. Thanks in advance
Attachments: |
STOP_Strat_L_STOP.vfs [28.49 KiB]
Downloaded 530 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
 |
jlongo
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Wed 12 Aug, 2015, 21:40
|
|
User rating: 94
Joined: Mon 06 Feb, 2012, 12:22 Posts: 357 Location: Portugal, Castelo Branco
|
Hi:
You have the answer and the changes needed to your strategy on other question you have done. You can change the first if value (1 to 0.001 or use the default variable "defaultTradeAmount" that is asked at every start of strategy and set it to any value you want and the strategy only opens 1 trade at time (don't forget to change the order command block to this variable too if using variable).
Regards
JL
|
|
|
|
 |
Korc
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Thu 13 Aug, 2015, 15:06
|
|
User rating: 0
Joined: Thu 16 Jul, 2015, 14:55 Posts: 17 Location: PolandPoland
|
Hi, I've just tested strategy implementing your suggestions before and... IT WORKS properly on DEMO acc. Now I can test it on Live acc. Thank you very much; we should drink coffee together
|
|
|
|
 |
API Support
|
Post subject: Re: How to stop strategy? |
Post rating: 0
|
Posted: Tue 18 Aug, 2015, 17:13
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
FYI Strategy self stop is prohibited on Strategy Contest.
|
|
|
|
 |
|
Pages: [
1
]
|
|
|
|
|