Yes, that's it. Looks like a bug in the Position Sizer, MetaTrader 5, or broker's server configuration. Unfortunately, I cannot test this on their Pro account. Do you get the same error when trying to open a slightly smaller or larger trade (0.49 or 0.51)?
Yes happens when I risk any %. Although this morning it was working on EURUSD, but now it isn't. I think yo ucan set up a trial account with Alpha to test it with?
 
Yes, I can, but it looks like automated trading is disabled server-side on trial accounts.
UPDATE: After a few back and forth DM's between myself and Enivid, we managed to get to the bottom of this issue.

I had enabled the 'CalculateUnadjustedPositionSize' to true because I though it could be more accurate and it seems my prop firm broker has restrictions on the lot size input. I put this setting back to false and the EA started taking trades again!

Once again thank you for your support, Enivid.
 
  • 🚀
  • ℹ️
Reactions: EnrichWave and Enivid
Problem

Position Sizer allows configuring which corner of the chart the panel should be placed through the PanelPositionCorner input, with options for all four corners: upper left, upper right, lower left, and lower right.
When setting the panel anchor to the right side of the chart, in a dual monitor setup, a positioning problem was identified. MetaTrader at normal size (when opening the program) opens on monitor 1 (left). When resizing the MetaTrader window to the right side (occupying monitor 2), the panel position did not follow correctly, ending up in different positions with each window size change.
The original EA behavior of saving each interface position change to the INI file also made it difficult to keep the panel in the same place when resizing the window. With each resize, a new (incorrect) position was saved, and that position was used as reference for the next calculation, creating inconsistency. Additionally, the constant I/O to the INI file brought some delay during transitions.
With the anchor on the left side, the problem did not occur, since the left corner of the chart remains fixed when the window is expanded to the right.
Solution

I added the LockPanelToCorner input that allows the user to choose between two behaviors:

false (default): Original behavior maintained — position is saved to INI file and panel can be dragged freely
true: Panel always calculates its position from the configured inputs (PanelPositionX, PanelPositionY, PanelPositionCorner), correctly following window resizing without saving to INI

This way I preserved the original code and logic for those who prefer the EA working the previous way, while I offered the new option for those who face the positioning problem.
Thanks, bro. Your additional code solved my problem, panel position constantly changing when I set x = -60 and y = -30 to save space on my old monitor. Also, big thanks to enivid for providing the best open position management tools on the planet.
 
  • 👍
Reactions: Nathan.Küster
Please I used it and passed an account. The prop firm is requesting for the source code and set files of the EA. Please how do I get it
The source code is available in the archive file that you downloaded to install the Position Sizer. Look for the Position Sizer subfolder in your \MQL5\Experts\ folder.
 
Thanks, bro. Your additional code solved my problem, panel position constantly changing when I set x = -60 and y = -30 to save space on my old monitor. Also, big thanks to enivid for providing the best open position management tools on the planet.
Which firm are you using?. Just tell them that you are using EA to manage the positions.

BR
 
Hello admin, everytime I try locking my position sizer to 1:2RR it never gives me 1:2RR and I have it locked to 2RR and when I lock it I always get 1:1.7/ or1.6 how do I fix that and I’m aware every time price move the EA needs to adjust but it not even close I’m expecting 1:1.98 or something near but is far off
 
Hello admin, everytime I try locking my position sizer to 1:2RR it never gives me 1:2RR and I have it locked to 2RR and when I lock it I always get 1:1.7/ or1.6 how do I fix that and I’m aware every time price move the EA needs to adjust but it not even close I’m expecting 1:1.98 or something near but is far off
Please show a screenshot of this. Most likely, this has to do with the commission. If you have non-zero commission and you want fixed TP/SL ratio to be the same as without the commission, then you need to set the UseCommissionToSetTPDistance input parameter to true.
 
In this version, with minor customizations for my personal use, I've rearranged the input parameters.


2026-01-24_103600.png


2026-01-24_103844.png


2026-01-24_103951.png

2026-01-24_104020.png


2026-01-24_104030.png
 

Attachments

Last edited:
Please show a screenshot of this. Most likely, this has to do with the commission. If you have non-zero commission and you want fixed TP/SL ratio to be the same as without the commission, then you need to set the UseCommissionToSetTPDistance input parameter to true.
Yeah it has something to do with the commission, how do I make it give me 1:2RR with commission
 

Attachments

  • image.jpg
    image.jpg
    233.8 KB · Views: 3