
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
ALGUEM ME AJUDA, eu nao sei o que fazer.
Someone helps me, i dont know what to do.
Remove this <chart>
Remove this <chart>
The poster tried to compile a template and you advise him to remove a tag and retry. What kind of help is this?
Someone helps me, i dont know what to do.
A template cannot be compiled, it needs to be MQL code. Files containg MQL end in .mq4, .mq5 or .mqh.
SOMEONE HELP ME, I don't know what to do.
Someone helps me, i dont know what to do.
Please post only in English on this forum. Use the automatic translation tool if needed. Use simple language structure when using mechanical translation.
Don't post pictures of code, they are too hard to read.
Please edit your (original) post and use the CODE button (Alt-S)! (For large amounts of code, attach it.)
General rules and best pratices of the Forum. - General - MQL5 programming forum 2019.05.06
Messages Editor
Hello Y'all,
So have been dealing with this problem for 2 days straight.
It says the following: '}' - unexpected end of program
'{' - Unbalanced parentheses
Can somebody help me please?
I am getting quit fed up
Copy and paste your code using the code button (Ctrl+S).
Do not attach a photo.
hello. Can anyone help me. I don't know how anymore. when compiling a script appears " '}-'unexpected end of program" and " '}-' unbalanced parenthases"
double OnTester()
{
double ret=0.0;
return(ret);
}
void OnChartEvent(const int id, const long &lparam,
const double &dparam,
const string &sparam)
{
}
void OnTick()
{ <----here's the fault.
tickvalue = SymbolInfoDouble(_Symbol,SYMBOL_TRADE_TICK_VALUE);
minlot = SymbolInfoDouble (_Symbol,SYMBOL_VOLUME_MIN);
lotstep = SymbolInfoDouble (_Symbol,SYMBOL_VOLUME_STEP);
MinLots = SymbolInfoDouble (_Symbol,SYMBOL_VOLUME_MIN);
for starters read the rules of the forum and follow those rules for posting!
2. put } at the end of MinLots line.
@Wesley Machado
void OnTick()
{
// Create variable for highest and lowes candle
int HighestCandle,LowestCandle;
// create Arrays for highest and lowest candle
double High[],Low[];
// sort array downwards from the current candle
ArraySetAsSeries(High,true);
// sort array downwards from the current candle
ArraySetAsSeries(Low,true);
// Fill array with data for 100 candle
CopyHigh(_Symbol,_Period,0,100,High);
// Fill array with data for 100 candle
CopyLow(_Symbol,_Period,0,100,Low);
// calculate the highest candle
HighestCandle= ArrayMaximum(High,0,100);
// calculate the highest candle
LowestCandle= ArrayManimum(Low,0,100);
// Create an Array for price
MqlRates PriceInformation[];
// Sort it from current candle to oldeat candle
ArraySetAsSeries(PriceInformation,true);
// Copy price data into the array
int Data-CopyRates(Symbol(),Period(),0,Bars(Symbol(),Period()),PriceInformation;
// Delete former Fibonacci object
ObjectDelete(_Symbol,"Fibonacci");
// Create the object
ObjectCreate
(
_Symbol, // current chart
"Fibonacci", // object name
OBJ_FIBO, // object type
0, // in main window
PriceInformation[100].time, // left border candle100
PriceInformation[HighestCandle].high, // upper border higheat candel
PriceInformation[0].time // right border candle0
PriceInformation[LowestCandle].low // lower border lowest candle
);
// Get values
datetime Datetime0 = ObjectGetInteger(0, "Fibonacci", OBJPROP_TIME,0);
double PriceLevel100 = ObjectGetDouble(0, "Fibonacci", OBJPROP_PRICE,0);
datetime DateTime1 = ObjectGetInteger(0, "Fibonacci", OBJPROP_TIME,1);
double PriceLeve10 = ObjectGetDouble(0, "Fibonacci", OBJPROP_PRICE,1);
double PriceLevel50=((PriceLevel100+PriceLeve10)*0.5);
// Create a Chart output
Comment (
"DateTime0: ", DateTime0,"\n",
"DateTime1: ", DateTime1,"\n",
"PriceLevel 0: ",PriceLevel0,"\n",
"PriceLevel 50: ",PriceLevel50,"\n",
"PriceLevel00: ",PriceLevel100
);
At compile time these are the errors!
';' - unexpected end of program
'{' - unbalanced parentheses
@Wesley Machado
void OnTick()
{
// Create variable for highest and lowes candle
int HighestCandle,LowestCandle;
// create Arrays for highest and lowest candle
double High[],Low[];
// sort array downwards from the current candle
ArraySetAsSeries(High,true);
// sort array downwards from the current candle
ArraySetAsSeries(Low,true);
// Fill array with data for 100 candle
CopyHigh(_Symbol,_Period,0,100,High);
// Fill array with data for 100 candle
CopyLow(_Symbol,_Period,0,100,Low);
// calculate the highest candle
HighestCandle= ArrayMaximum(High,0,100);
// calculate the highest candle
LowestCandle= ArrayManimum(Low,0,100);
// Create an Array for price
MqlRates PriceInformation[];
// Sort it from current candle to oldeat candle
ArraySetAsSeries(PriceInformation,true);
// Copy price data into the array
int Data-CopyRates(Symbol(),Period(),0,Bars(Symbol(),Period()),PriceInformation;
// Delete former Fibonacci object
ObjectDelete(_Symbol,"Fibonacci");
// Create the object
ObjectCreate
(
_Symbol, // current chart
"Fibonacci", // object name
OBJ_FIBO, // object type
0, // in main window
PriceInformation[100].time, // left border candle100
PriceInformation[HighestCandle].high, // upper border higheat candel
PriceInformation[0].time // right border candle0
PriceInformation[LowestCandle].low // lower border lowest candle
);
// Get values
datetime Datetime0 = ObjectGetInteger(0, "Fibonacci", OBJPROP_TIME,0);
double PriceLevel100 = ObjectGetDouble(0, "Fibonacci", OBJPROP_PRICE,0);
datetime DateTime1 = ObjectGetInteger(0, "Fibonacci", OBJPROP_TIME,1);
double PriceLeve10 = ObjectGetDouble(0, "Fibonacci", OBJPROP_PRICE,1);
double PriceLevel50=((PriceLevel100+PriceLeve10)*0.5);
// Create a Chart output
Comment (
"DateTime0: ", DateTime0,"\n",
"DateTime1: ", DateTime1,"\n",
"PriceLevel 0: ",PriceLevel0,"\n",
"PriceLevel 50: ",PriceLevel50,"\n",
"PriceLevel00: ",PriceLevel100
);
At compile time these are the errors!
';' - unexpected end of program
'{' - unbalanced parentheses