- www.mql5.com
- Manual charting and trading toolkit (Part I). Preparation: structure description and helper class
- Trade Server Return Codes
- someone assist me pls, am trying to code and cant make this EA to work sell and buy orders, as its only opening sell order
I will move your topic to the MQL4 and Metatrader 4 section.
You would do better to take the time to learn coding instead of using an EA Builder.
Part of the terms of using an EA builder are to not remove the heading, but you have removed it.
- vuthg0106:
I'm a non-programmer, but I'm trying to code hedging as shown.
I am having a problem like this:
I first open a buy order and a pending order at the same time.
When the price increases and touches the TP of the buy order, it deletes the pending order (when the pending order does not turn into an order field).
When the price goes down to the point of a pending sell order , the pending sell order changes to a sell market order and immediately opens another pending buy order (the pending order changes to a field order while opening new pending orders. command and number). Command OrderSelec is Connecting next order)
As in the code below I have compiled, however it does not run properly.
Hope someone help me
Thank you very much
Please post only in English on this forum. Use the automatic translation tool if needed. Use simple language structure when using mechanical translation.
-
Hedging, grid trading, same as Martingale.
Martingale, guaranteed to blow your account eventually. If it's not profitable without, it is definitely not profitable with.
Martingale vs. Non Martingale (Simplified RoR vs Profit and the Illusions) - MQL5 programming forum 2015.02.11Why it won't work: Calculate Loss from Lot Pips - MQL5 programming forum 2017.07.11
-
ngày giờ tĩnh t; if (t == Thời gian [ 0 ]) return ( 0 ); int vé 1 , vé 2 , vé 3 , vé 4 , vé 5 , vé 6 , vé 7 ; tổng số int ; if (điều kiện == true )
Those lines are not valid code. Variable names and type names can not have spaces. Do not post code that will not even compile; don't waste everyone's time.
- EA builder, EA Builder Pro, EATree, Etasoft forex generator, Forex Strategy Builder, FOREXEADVISOR STRATEGY BUILDER, FX EA Builder, fxDreema, FxPro, Molanis, Online Forex Expert Advisor Generator, Strategy Builder FX, Strategy Quant, Visual Trader Studio, MQL5 Wizard, etc., are all the same. You will get something quick, but then you will spend a much longer time trying to get it right, than if you learned the language up front, and then just wrote it.
-
Since you haven't learned MQL4/5, therefor there is no common language for us to communicate.
If we tell you what you need, you can't code it.
If we give you the code, you don't know how to integrate it into yours.
We are willing to HELP you when you post your attempt (using SRC) and state the nature of your problem, but we are not going to debug your hundreds of lines of code. You are essentially going to be on your own. -
EA builder makes bad code counting up while closing multiple orders.
EA builder makes bad code Bars is unreliable (Max bars in chart), volume is unreliable (miss ticks.) Always use time.
EA builder makes bad code, not adjusting for 4/5 digit brokers, TP/SL and slippage.
EA builder makes bad code, not adjusting for ECN brokers. pre-Build 500)
EA builder makes bad code, not checking return codes. -
EATree uses objects on chart to save values — not persistent storage (files or GV+Flush.) No recovery (crash/power failure.)
-
FX EA Builder makes bad code, not checking return codes.
FX EA Builder makes bad code, loosing open tickets on terminal restart. No recovery (crash/power failure.)
FX EA Builder makes bad code, not adjusting stops for the spread.
FX EA Builder makes bad code, using OrdersTotal directly. -
FOREXEADVISOR STRATEGY BUILDER makes bad code, non-updateing global variables.
FOREXEADVISOR STRATEGY BUILDER makes bad code, compilation errors.
FOREXEADVISOR STRATEGY BUILDER makes bad code, not checking return codes.
Learn to code it, or pay someone (Freelance) someone to code it.
Hiring to write script - General - MQL5 programming forum #1 2019.08.21 -
-
for (int i = OrderTotal () - 1; i> = 0; i--){ OrderSelect (i, SELECT_BY_POS, MODE_TRADES); Type2 = OrderType (); Order2 = OrderTicket (); if (OrderSymbol () == Symbol ()){ OrderSelect (i-1, SELECT_BY_POS, MODE_TRADES)
When i becomes zero your second OrderSelect fails.Check your return codes, and report your errors (including market prices and your variables). Don't look at GLE/LE unless you have an error. Don't just silence the compiler (strict), it is trying to help you.
What are Function return values ? How do I use them ? - MQL4 programming forum 2012.05.20
Common Errors in MQL4 Programs and How to Avoid Them - MQL4 Articles 25 March 2014
This is an English language forum.
I have deleted whatever you had written in your first post. I am sure that it was originally English.
Post only in English please and that includes when quoting other people's posts. Do not quote them when they have been translated to your language.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use