I am beginner, any one guide me fix this error
1. Please insert the code correctly: when editing a message, press the button and paste your code into the pop-up window.
2. A simple advisor: there are always two opposite positions in the market
- 2021.11.13
- www.mql5.com
-
What error? You haven't stated any. Do you really expect an answer? There are no mind readers here and our crystal balls are cracked.
How To Ask Questions The Smart Way. (2004)
Be precise and informative about your problem -
input int TakeProfitInPips = 500; //TakeProfit pips ⋮ double TakeProfit = Ask + TakeProfitInPips*_Point;
A PIP is not a point.
PIP, Point, or Tick are all different in general.
What is a TICK? - MQL4 programming forum (2014)Unless you manually adjust your SL/TP for each separate symbol, using Point means code breaks on 4 digit brokers, exotics (e.g. USDZAR where spread is over 500 points), and metals. Compute what a PIP is and use it, not points.
How to manage JPY pairs with parameters? - MQL4 programming forum (2017)
Slippage defined in index points - Expert Advisors and Automated Trading - MQL5 programming forum (2018) -
You buy at the Ask and sell at the Bid. Pending Buy Stop orders become market orders when hit and open at the Ask.
-
You buy at the Ask and sell at the Bid. Pending Buy Stop orders become market orders when hit and open at the Ask.
-
Your buy order's TP/SL (or Sell Stop's/Sell Limit's entry) are triggered when the Bid / OrderClosePrice reaches it. Using Ask±n, makes your SL shorter and your TP longer, by the spread. Don't you want the specified amount used in either direction?
-
Your sell order's TP/SL (or Buy Stop's/Buy Limit's entry) will be triggered when the Ask / OrderClosePrice reaches it. To trigger close to a specific Bid price, add the average spread.
MODE_SPREAD (Paul) - MQL4 programming forum - Page 3 #25 -
The charts show Bid prices only. Turn on the Ask line to see how big the spread is (Tools → Options (control+O) → charts → Show ask line.)
Most brokers with variable spreads widen considerably at end of day (5 PM ET) ± 30 minutes. My GBPJPY shows average spread = 26 points, but average maximum spread = 134 (your broker will be similar).
-
-
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I am beginner, any one guide me fix this error