- www.mql5.com
There seems to be a miscommunication here.
There is a difference between "properties" and "property values".
In your initial post you ask about creating new "properties". You did not ask about to their values being the same as the previous usage in the GUI.
Please explain in more detail.
Your question is unclear. I am unable to understand your question. Please explain in more detail, hopefully with a code sample and possibly a screenshot or two.
Your question is unclear. I am unable to understand your question. Please explain in more detail, hopefully with a code sample and possibly a screenshot or two.
Please provide sample code to reproduce the issue.
void OnStart(void) { ObjectCreate(0,"First",OBJ_BITMAP,0,iTime(NULL,0,0),iClose(NULL,0,0)); ObjectSetString(0,"First",OBJPROP_BMPFILE,"\\Images\\dollar.bmp"); ObjectSetInteger(0,"First",OBJPROP_TIMEFRAMES,OBJ_NO_PERIODS); ObjectCreate(0,"Second",OBJ_BITMAP,0,iTime(NULL,0,0),iClose(NULL,0,0)); ObjectSetString(0,"Second",OBJPROP_BMPFILE,"\\Images\\euro.bmp"); ObjectSetInteger(0,"First",OBJPROP_TIMEFRAMES,OBJ_ALL_PERIODS); ChartRedraw(); }
Yes, you are correct! I have tested your code and I have also tested various combinations of different sequence of the code.
I also experimented with the Z Order to see if it would affect it, but it did not.
Every time one changes the "period" visibility, it brings the object to the top.
I don't know if this can be classified as a bug or if there is some other explanation, but I could not find anything in the documentation to explain the behaviour.
Every time one changes the "period" visibility, it brings the object to the top.
We can probably state that when OBJPROP_TIMEFRAMES is changed, the object is moved to the top, just like when an object is created. Then all that remains is to simply take this into account.
I delete and re-create the dashboard every time after creating OBJ_HLINE (I'm talking about OBJ_HLINE, which are created by the same advisor/indicator. I do not track objects created by other programs or manually)
(And this experience was in MQL4, but I think that in MQL5 things are exactly the same).
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use