Marbo:
Hi guys,
I open some charts, draw some lines and rectangles and then I drag the following script into one of the charts.
This script should print the names and types of the objects found in all charts. Interestingly, the names are all correct but the object types are all -1 except the objects of the chart I drag the script into.
But why?!?! How can the name be correct and the object type is -1?
This is the script:
Should use
int objType = ObjectGetInteger(ChartID,objName,OBJPROP_TYPE);
instead.
Seng Joo Thio:
Should use
instead.
That works perfect! Thank you very much!

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
Hi guys,
I open some charts, draw some lines and rectangles and then I drag the following script into one of the charts.
This script should print the names and types of the objects found in all charts. Interestingly, the names are all correct but the object types are all -1 except the objects of the chart I drag the script into.
But why?!?! How can the name be correct and the object type is -1?
This is the script: