pepperb

Trader
Aug 8, 2022
12
1
14
49
I've been having an issue with both the original MT5 Position Size Calculator indicator, and now the Position Sizer EA. It worked great with my 5%ers Broker and my EightCap for a year, then about a month ago it stopped working on The5%ers, giving me "unknown retcode 16" error, where it wouldn't send the trade at market. It would send a pending order. So I downloaded the new Position Sizer EA and it worked for a day, then stopped working. So I updated it last week. It worked on Friday, but today I'm back to the same error code, only now I have the same issue on Eightcap. It seems like each time I download a new version it only works for a day or two before it stops sending the market orders and gives me the "retcode 16" error. I've checked with my broker and they don't see any issues on their end.

Any ideas?
 

simoncs

Newbie
Aug 9, 2022
3
3
3
49
Hi
i am having an issue with one broker whish I am performing a challenge with. They keep closing my positions as they are not set with a stoploss. I checked the logs and it seems that the tool originally creates an order without a SL or TP, but then modifies the order immediately and adds them back in afterwards - so effectively another transaction. They must have scripts that read the first order, and then cancel my trades.
Is there a way to fix this?

thanks
 

EnrichWave

Master Trader
May 15, 2018
325
82
74
India
Hi
i am having an issue with one broker whish I am performing a challenge with. They keep closing my positions as they are not set with a stoploss. I checked the logs and it seems that the tool originally creates an order without a SL or TP, but then modifies the order immediately and adds them back in afterwards - so effectively another transaction. They must have scripts that read the first order, and then cancel my trades.
Is there a way to fix this?

thanks
I think your answer is here.
https://www.earnforex.com/forum/threads/position-sizer.47384/post-211418

I've been having an issue with both the original MT5 Position Size Calculator indicator, and now the Position Sizer EA. It worked great with my 5%ers Broker and my EightCap for a year, then about a month ago it stopped working on The5%ers, giving me "unknown retcode 16" error, where it wouldn't send the trade at market. It would send a pending order. So I downloaded the new Position Sizer EA and it worked for a day, then stopped working. So I updated it last week. It worked on Friday, but today I'm back to the same error code, only now I have the same issue on Eightcap. It seems like each time I download a new version it only works for a day or two before it stops sending the market orders and gives me the "retcode 16" error. I've checked with my broker and they don't see any issues on their end.

Any ideas?
Its weird one. It's on windows Platform or in Mac?
 

simoncs

Newbie
Aug 9, 2022
3
3
3
49
I think your answer is here.
https://www.earnforex.com/forum/threads/position-sizer.47384/post-211418


Its weird one. It's on windows Platform or in Mac?
thanks for the quick reply -- it's on Windows - the broker is also Eightcap. Interestingly, I have not seen this with other brokers when placing the Instant order (pendings work fine), FTMO is not an issue, and nor was TCBridge
The prop firm obviously have some kind of screener their end that closes trades if they see them opened without a SL - I have asked them if they could modify that process to add a time delay to it, just incase it can't be fixed at source.
 

Mosaic455

Newbie
Aug 9, 2022
2
0
1
25
Version 3.01 released with a hotfix for the breakeven and hotkey bugs.
Hi there Enivid. I would like to thank you for that awesome EA. It has made execution easier for me. The breakeven option is stuff of genius!
If I could make a suggestion for improvement, would you please add an option to preset Default Take-Profit levels for Multiple TP. For instance, if i choose to have 3 TP levels, I would like to have the option of presetting their Target levels beforehand, so that once i enter a trade I don have to manually set them. Say if I want TP1 to always be 5.0 pips, TP2 to always be 8.0 pips and full TP to always be 12.0 pips.
Another suggestion could be to have an option to close 80% (or any %) of full TP at a preset profit level, for instance in the above example, I could have the option to close 80% of full TP (12.0 pips) once price hits 10.0 pips profit, thereby leaving 20% of my position to ride to full TP.
I will highly appreciate your consideration of this request. Regards.
 

Enivid

Administrator
Staff member
Nov 30, 2008
18,530
1,355
144
Odesa
www.earnforex.com
I've been having an issue with both the original MT5 Position Size Calculator indicator, and now the Position Sizer EA. It worked great with my 5%ers Broker and my EightCap for a year, then about a month ago it stopped working on The5%ers, giving me "unknown retcode 16" error, where it wouldn't send the trade at market. It would send a pending order. So I downloaded the new Position Sizer EA and it worked for a day, then stopped working. So I updated it last week. It worked on Friday, but today I'm back to the same error code, only now I have the same issue on Eightcap. It seems like each time I download a new version it only works for a day or two before it stops sending the market orders and gives me the "retcode 16" error. I've checked with my broker and they don't see any issues on their end.

Any ideas?
Seeing the actual output from the Experts tab would be helpful.
 

Enivid

Administrator
Staff member
Nov 30, 2008
18,530
1,355
144
Odesa
www.earnforex.com
Hi
i am having an issue with one broker whish I am performing a challenge with. They keep closing my positions as they are not set with a stoploss. I checked the logs and it seems that the tool originally creates an order without a SL or TP, but then modifies the order immediately and adds them back in afterwards - so effectively another transaction. They must have scripts that read the first order, and then cancel my trades.
Is there a way to fix this?

thanks
Your broker uses Market execution model where market orders can only be submitted without SL and TP attached to them. SL and TP can only be added later to them.
 

Enivid

Administrator
Staff member
Nov 30, 2008
18,530
1,355
144
Odesa
www.earnforex.com
Hi there Enivid. I would like to thank you for that awesome EA. It has made execution easier for me. The breakeven option is stuff of genius!
If I could make a suggestion for improvement, would you please add an option to preset Default Take-Profit levels for Multiple TP. For instance, if i choose to have 3 TP levels, I would like to have the option of presetting their Target levels beforehand, so that once i enter a trade I don have to manually set them. Say if I want TP1 to always be 5.0 pips, TP2 to always be 8.0 pips and full TP to always be 12.0 pips.
Another suggestion could be to have an option to close 80% (or any %) of full TP at a preset profit level, for instance in the above example, I could have the option to close 80% of full TP (12.0 pips) once price hits 10.0 pips profit, thereby leaving 20% of my position to ride to full TP.
I will highly appreciate your consideration of this request. Regards.
The multiple TP facility was added exactly to work as a partial close function. In your example, you would open two trades - one with 80% of the volume with a lower TP and one with 20% of the volume with a higher TP.

As for the preset multiple TP levels, I will consider that idea.
 
  • 👍
Reactions: Mosaic455

simoncs

Newbie
Aug 9, 2022
3
3
3
49
Your broker uses Market execution model where market orders can only be submitted without SL and TP attached to them. SL and TP can only be added later to them.
just an update - -i spoke to the Prop firm (Surge Trader) and they have changed their scanner time period to cater for this, so it now works with all orders. Thanks!
 
  • 👍
  • ℹ️
Reactions: Enivid and EnrichWave

KarlWS

Trader
Aug 11, 2022
5
0
12
33
Discuss the Position Sizer expert advisor here. This EA lets you calculate optimal position size and execute trades based on these calculations. Based on Position Size Calculator, it allows some additional control over the trades it opens. You can ask any questions about this free MetaTrader tool here.


Hi, I am having some difficulty getting the MQ4 Position Sizer file to compile in MT4.

I have followed the following steps to compile the file: MT4 > File > Open Data Folder > Double click the MQ4 Position Sizer file to compile in MT4 > however, I cannot get passed this stage. Once I select the file I see a small loading icon, yet nothing progresses.

Can you advise how to overcome this problem?

Thanks!
 

Enivid

Administrator
Staff member
Nov 30, 2008
18,530
1,355
144
Odesa
www.earnforex.com
Hi, I am having some difficulty getting the MQ4 Position Sizer file to compile in MT4.

I have followed the following steps to compile the file: MT4 > File > Open Data Folder > Double click the MQ4 Position Sizer file to compile in MT4 > however, I cannot get passed this stage. Once I select the file I see a small loading icon, yet nothing progresses.

Can you advise how to overcome this problem?
Launch MetaEditor from within your MT4 (press F4) and open the Position Sizer.mq4 in MetaEditor. Then compile by pressing F7.
 
  • 👍
Reactions: KarlWS

KarlWS

Trader
Aug 11, 2022
5
0
12
33
Launch MetaEditor from within your MT4 (press F4) and open the Position Sizer.mq4 in MetaEditor. Then compile by pressing F7.
Thank you, that has now worked!

I have however, run into another issue. I can now see the Position Sizer in my indicators list. But, I am unable to add it to my chart. After clicking add to chart, I can see an error message in my Journal. See attached.

Are you able to advise how I can add the indicator to my chart?

Thanks!
 

Attachments

  • Position sizer error.PNG
    Position sizer error.PNG
    163.2 KB · Views: 4

Enivid

Administrator
Staff member
Nov 30, 2008
18,530
1,355
144
Odesa
www.earnforex.com
Thank you, that has now worked!

I have however, run into another issue. I can now see the Position Sizer in my indicators list. But, I am unable to add it to my chart. After clicking add to chart, I can see an error message in my Journal. See attached.

Are you able to advise how I can add the indicator to my chart?

Thanks!
That's because the Position Sizer is not an indicator, it is an expert advisor and should be installed in the Experts subfolder in your MQL4 folder.
 

KarlWS

Trader
Aug 11, 2022
5
0
12
33
That's because the Position Sizer is not an indicator, it is an expert advisor and should be installed in the Experts subfolder in your MQL4 folder.
Perfect, that has worked. Thank you! I was following a youtube video for the install..
 

Mosaic455

Newbie
Aug 9, 2022
2
0
1
25
that will be very helpful, again thanks for your consideration, this platform and your contribution to the industry.
The multiple TP facility was added exactly to work as a partial close function. In your example, you would open two trades - one with 80% of the volume with a lower TP and one with 20% of the volume with a higher TP.

As for the preset multiple TP levels, I will consider
 

Crash101

Trader
Jul 25, 2021
26
2
19
51
Any chance of adding an option for spread addition for sell positions on stop loss position?

Awesome work brother. Thanks for this good Expert Advisor.

Crashcourse!!
 

Enivid

Administrator
Staff member
Nov 30, 2008
18,530
1,355
144
Odesa
www.earnforex.com
The Position Sizer EA has been updated to version 3.02 to fix some bugs and make some minor changes:
  1. Fixed a bug that could result in wrong position size calculation when switching the chart's symbol in MT5. (Via a Github issue.)
  2. Fixed the Commentary and Auto-Suffix fields which weren't working correctly in MT5. (@CARPARK)
  3. Fixed a bug that prevented newly set default input parameters to change the respective fields on the panel.
  4. Fixed a bug that could result in reward-related Main tab elements to show up when some other tab was selected.
  5. Fixed a bug that sometimes prevented the Position Size field change from registering when the panel was calculating the Risk based on the Position Size.
  6. Moved the ShowATROptions input parameter to the Compactness inputs group.
  7. Removed the redundant Stop Price Label Color input parameter as there is no such label in MT5.
  8. Made some purely cosmetic changes.
 
  • 👍
  • 🎉
Reactions: EnrichWave and CARPARK