when all else fails, search whroeder's posts......
case solved..... even though my prior code had always worked, perhaps it was not correct...
still not clear why only currency futures were effected..... might look into it deeper...... might not......h
//-----
ObjectCreate(0,"Buy",OBJ_BUTTON,0,0,0); ObjectCreate(0,"Buy Limit",OBJ_BUTTON,0,0,0); ObjectCreate(0,"Buy Stop",OBJ_BUTTON,0,0,0); ObjectCreate(0,"Sell",OBJ_BUTTON,0,0,0); ObjectCreate(0,"Sell Limit",OBJ_BUTTON,0,0,0); ObjectCreate(0,"Sell Stop",OBJ_BUTTON,0,0,0); ObjectCreate(0,"Close",OBJ_BUTTON,0,0,0); ObjectCreate(0,"Close All",OBJ_BUTTON,0,0,0); ObjectCreate(0,"Profit",OBJ_BUTTON,0,0,0); //---- //---- ObjectSetInteger(0,"Buy",OBJPROP_XDISTANCE,10); // ObjectSetInteger(0, ...... using _Symbol had always worked however on currency futures it did not..... must use '0'...... ObjectSetInteger(0,"Buy",OBJPROP_XSIZE,200); ObjectSetInteger(0,"Buy",OBJPROP_YDISTANCE,50); ObjectSetInteger(0,"Buy",OBJPROP_YSIZE,40); ObjectSetInteger(0,"Buy",OBJPROP_CORNER,0); ObjectSetString(0,"Buy",OBJPROP_TEXT,"Buy"); ObjectSetInteger(0,"Buy",OBJPROP_BGCOLOR,clrAqua);
are you returning INIT_SUCCEEDED from OnInit()? because it's important to do that for successful initialization when you use int OnInit() and not void OnInit()
Conor Mcnamara #:
are you returning INIT_SUCCEEDED from OnInit()? because it's important to do that for successful initialization when you use int OnInit() and not void OnInit()
are you returning INIT_SUCCEEDED from OnInit()? because it's important to do that for successful initialization when you use int OnInit() and not void OnInit()
//----
hey conor....... thanks for the reply...... yes i am.....
mentioned over on enivids site that had thought it might have to do with futures starting with a 6.....
enivid agreed..... it was a compound error on my part which just by chance had always worked ok before......
and again, thanks for the reply......h

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
seems about once every 10 or so years i have a gee whiz type question.....
ObjectCreate is pretty straight forward and can never recall a problem..... till i noticed on currency futures the objectcreate will not create the buttons in the code below..... i have googled and mq5 booked it to death.....
it will work perfectly on everything else..... on currency futures it returns error 4101, wrong chart id..... have never noticed that error before.....
including the chart_id just leads to cascading errors......
i'm still working on it, but does anyone have an idea....... it's mq5, not mq4...... thanks......h