I have no knowledge of coding yet while compiling an ea i managed to reduce the 15 errors to just 2, both are the same '' 'if' - open parenthesis expected '' and when i click on this error it leads me to this point in the code which i cannot rectify
void tick22()
{if {tick22==true} {
and the cusor is just after the curly bracket before if
i changed this code " {if (tick22==true) { " to the above " {if {tick22==true} { " and reduced 15 errors to 2 errors
can anyone help me please
Next time use SRC button to post the code
do this
void tick22() { if (tick22==true) { } }
Be careful when writing parenthesis { and } with ( and ).
Hope you have define tick22 variable before coz if not you will have more error though .
- Please don't post image, of code.
When you post code please use the CODE button (Alt-S)!
(For large amounts of code,
attach it.)
Please edit
your post.
General rules and best pratices of the Forum. - General - MQL5 programming forum
Messages Editor - Your code is
if {myAccountEquity - myAccountBalance) > 10 ( CloseAllOrders(); )
Look at the documentation.
Conditional Operator if-else - Operators - Language Basics - MQL4 Reference
The if statement form is if ( condition ) statement; or if ( condition ) { controlled; statements; }. Your code doesn't have an open parenthesis (per the error message.) It has an open brace.
Correct brackets/bracers {} - MQL4 and MetaTrader 4 - MQL4 programming forum - Page 2 - You have a closing parenthesis without an open
- You have no closing parenthesis after the end of your condition.
- You have no braces for your controlled statements.
- Please don't post image, of code.
When you post code please use the CODE button (Alt-S)!
(For large amounts of code,
attach it.)
Please edit
your post.
General rules and best pratices of the Forum. - General - MQL5 programming forum
Messages Editor - Your code isLook at the documentation.
Conditional Operator if-else - Operators - Language Basics - MQL4 Reference
The if statement form is if ( condition ) statement; or if ( condition ) { controlled; statements; }. Your code doesn't have an open parenthesis (per the error message.) It has an open brace.
Correct brackets/bracers {} - MQL4 and MetaTrader 4 - MQL4 programming forum - Page 2 - You have a closing parenthesis without an open
- You have no closing parenthesis after the end of your condition.
- You have no braces for your controlled statements.
- What part of "Please don't post image of code" was unclear?
- What part of "if ( condition ) { controlled; statements; }" was unclear?
if { myAccountEquitey - myAccountBalance) > 10)} ( CloseAllOrders(); )
- What part of "You have a closing parenthesis without an open" was unclear?
No you didn't.
- What part of "Please don't post image of code" was unclear?
- What part of "if ( condition ) { controlled; statements; }" was unclear?
- What part of "You have a closing parenthesis without an open" was unclear?
No you didn't.
- What part of "Please don't post image of code" was unclear?
- What part of "if ( condition ) { controlled; statements; }" was unclear?
- What part of "You have a closing parenthesis without an open" was unclear?
if {(myAccountEquity - myAccountBalance) >[5])}
(
CloseAllOrders ()
)
I asked you to use code button twice. Ignored three times (two images and one text.)
I showed you the difference between parentheses () and braces {} but you refuse to look, read, and learn.
Go to freelance and pay someone. I doubt anyone here can help you.

- 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 have no knowledge of coding yet while compiling an ea i managed to reduce the 15 errors to just 2, both are the same '' 'if' - open parenthesis expected '' and when i click on this error it leads me to this point in the code which i cannot rectify
void tick22()
{if {tick22==true} {
and the cusor is just after the curly bracket before if
i changed this code " {if (tick22==true) { " to the above " {if {tick22==true} { " and reduced 15 errors to 2 errors
can anyone help me please