Position & Risk
Size exposure using equity, stop distance and actual specifications.
Search official trade, runtime and compilation codes and warnings. Calculate risk using actual contract specifications.
Size exposure using equity, stop distance and actual specifications.
Estimate margin, tick value and price-move value.
A mathematical scenario, not a forecast of strategy returns.
Calculations run locally in your browser. Inputs are not uploaded or saved. Terminal and broker margin rules apply; estimates exclude slippage, commission and swap.
1171 matching records
| Platform / category | Code / constant | Official meaning | Troubleshooting |
|---|---|---|---|
| MT4 · Trade return codes | 65 ERR_INVALID_ACCOUNT | Invalid account | YI GOLD suggestionsCheck permissions, sessions, symbol specifications, quotes and request parameters. Reproduce in a demo account. Do not retry rejected requests indefinitely. MetaQuotes |
| MT4 · Trade return codes | 128 ERR_TRADE_TIMEOUT | Trade timeout | YI GOLD suggestionsInspect connectivity, logs and request time. Verify actual order status before bounded retries with backoff to avoid duplicate exposure after a timeout. MetaQuotes |
| MT4 · Trade return codes | 129 ERR_INVALID_PRICE | Invalid price | YI GOLD suggestionsRead the latest bid/ask and quote time. Check precision and allowed deviation; stop increasing exposure with stale quotes. MetaQuotes |
| MT4 · Trade return codes | 130 ERR_INVALID_STOPS | Invalid stops | YI GOLD suggestionsCheck bid/ask, point, digits, stops_level and freeze_level. Recalculate distances; do not remove protection merely to force a fill. MetaQuotes |
| MT4 · Trade return codes | 131 ERR_INVALID_TRADE_VOLUME | Invalid trade volume | YI GOLD suggestionsRead volume_min, volume_max, volume_step and volume_limit for the actual symbol. Round down to the step; do not send an order below minimum volume. MetaQuotes |
| MT4 · Trade return codes | 132 ERR_MARKET_CLOSED | Market is closed | YI GOLD suggestionsCheck server time, gold trading sessions, holidays and terminal/EA permissions. Wait for availability instead of repeatedly retrying closed-market requests. MetaQuotes |
| MT4 · Trade return codes | 133 ERR_TRADE_DISABLED | Trade is disabled | YI GOLD suggestionsCheck server time, gold trading sessions, holidays and terminal/EA permissions. Wait for availability instead of repeatedly retrying closed-market requests. MetaQuotes |
| MT4 · Trade return codes | 134 ERR_NOT_ENOUGH_MONEY | Not enough money | YI GOLD suggestionsCheck actual account denomination, free margin, volume and leverage. Calculate margin in the terminal and assess reduced exposure or genuine funding. Do not repeatedly submit the same request. MetaQuotes |
| MT4 · Trade return codes | 135 ERR_PRICE_CHANGED | Price changed | YI GOLD suggestionsRead the latest bid/ask and quote time. Check precision and allowed deviation; stop increasing exposure with stale quotes. MetaQuotes |
| MT4 · Trade return codes | 136 ERR_OFF_QUOTES | Off quotes | YI GOLD suggestionsRead the latest bid/ask and quote time. Check precision and allowed deviation; stop increasing exposure with stale quotes. MetaQuotes |
| MT4 · Trade return codes | 137 ERR_BROKER_BUSY | Broker is busy | YI GOLD suggestionsSerialize account requests, verify previous outcomes, reduce frequency and use bounded backoff. MetaQuotes |
| MT4 · Trade return codes | 138 ERR_REQUOTE | Requote | YI GOLD suggestionsRead the latest bid/ask and quote time. Check precision and allowed deviation; stop increasing exposure with stale quotes. MetaQuotes |
| MT4 · Trade return codes | 139 ERR_ORDER_LOCKED | Order is locked | YI GOLD suggestionsSerialize account requests, verify previous outcomes, reduce frequency and use bounded backoff. MetaQuotes |
| MT4 · Trade return codes | 140 ERR_LONG_POSITIONS_ONLY_ALLOWED | Buy orders only allowed | YI GOLD suggestionsCheck permissions, sessions, symbol specifications, quotes and request parameters. Reproduce in a demo account. Do not retry rejected requests indefinitely. MetaQuotes |
| MT4 · Trade return codes | 141 ERR_TOO_MANY_REQUESTS | Too many requests | YI GOLD suggestionsSerialize account requests, verify previous outcomes, reduce frequency and use bounded backoff. MetaQuotes |
| MT4 · Trade return codes | 145 ERR_TRADE_MODIFY_DENIED | Modification denied because order is too close to market | YI GOLD suggestionsCheck permissions, sessions, symbol specifications, quotes and request parameters. Reproduce in a demo account. Do not retry rejected requests indefinitely. MetaQuotes |
| MT4 · Trade return codes | 146 ERR_TRADE_CONTEXT_BUSY | Trade context is busy | YI GOLD suggestionsSerialize account requests, verify previous outcomes, reduce frequency and use bounded backoff. MetaQuotes |
| MT4 · Trade return codes | 147 ERR_TRADE_EXPIRATION_DENIED | Expirations are denied by broker | YI GOLD suggestionsCheck permissions, sessions, symbol specifications, quotes and request parameters. Reproduce in a demo account. Do not retry rejected requests indefinitely. MetaQuotes |
| MT4 · Trade return codes | 148 ERR_TRADE_TOO_MANY_ORDERS | The amount of open and pending orders has reached the limit set by the broker | YI GOLD suggestionsCheck permissions, sessions, symbol specifications, quotes and request parameters. Reproduce in a demo account. Do not retry rejected requests indefinitely. MetaQuotes |
| MT4 · Trade return codes | 149 ERR_TRADE_HEDGE_PROHIBITED | An attempt to open an order opposite to the existing one when hedging is disabled | YI GOLD suggestionsCheck permissions, sessions, symbol specifications, quotes and request parameters. Reproduce in a demo account. Do not retry rejected requests indefinitely. MetaQuotes |
| MT4 · Trade return codes | 150 ERR_TRADE_PROHIBITED_BY_FIFO | An attempt to close an order contravening the FIFO rule | YI GOLD suggestionsCheck permissions, sessions, symbol specifications, quotes and request parameters. Reproduce in a demo account. Do not retry rejected requests indefinitely. MetaQuotes |
| MT4 · Compiler warnings | 21 | Incomplete record of a date in the datetime string | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 22 | Wrong number in the datetime string for the date. Requirements: Year 1970 <= X <= 3000 Month 0 <X <= 12 Day 0 <X <= 31/30/28 (29 ).... | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 23 | Wrong number of datetime string for time. Requirements: Hour 0 <= X <24 Minute 0 <= X <60 | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 24 | Invalid color in RGB format: one of RGB components is less than 0 or greater than 255 | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 25 | Unknown character of the escape sequences. Known: \n \r \t \\ \" \' \X \x | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 26 | Too large volume of local variables (> 512Kb) of the function, reduce the number | YI GOLD suggestionsRead volume_min, volume_max, volume_step and volume_limit for the actual symbol. Round down to the step; do not send an order below minimum volume. MetaQuotes |
| MT4 · Compiler warnings | 29 | Enumeration already defined (duplication) - members will be added to the first definition | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 30 | Overriding macro | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 31 | The variable is declared but is not used anywhere | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 32 | Constructor must be of void type | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 33 | Destructor must be of void type | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 34 | Constant does not fit in the range of integers (X> _UI64_MAX | | X <_I64_MIN) and will be converted to the double type | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 35 | Too long HEX - more than 16 significant characters (senior nibbles are cut) | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 36 | No nibbles in HEX string "0x" | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 37 | No function - nothing to be performed | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 38 | A non-initialized variable is used | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 41 | Function has no body, and is not called | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 43 | Possible loss of data at typecasting. Example: int x = (double) z; | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
| MT4 · Compiler warnings | 44 | Loss of accuracy (of data) when converting a constant. Example: int x = M_PI | YI GOLD suggestionsReview the warning line, types, initialization and return values in MetaEditor. Evaluate runtime consequences and correct the warning even when compilation succeeds. MetaQuotes |
Official meanings and YI GOLD suggestions are presented separately. References are verified during version builds; page visits do not fetch external sites.