Object on the right place

 

I want to to create a line with according to pixels not with price and time...

On my "trading view" I would like to have "mini-charts" with different time frames, like the picture I linked to...

http://www.mediafire.com/i/?2hnu70cc2pjw6s0

A work around could be a loop with text like "dots" (.), like below (with no loop)... But this would proberly look like #¤%&:

iCorner=0;
iXDistance=10;
iYDistance=10;
ObjectCreate("MT4", OBJ_LABEL, WindowFind("Somewhere"), 0, 0);
ObjectSetText(("MT4", ".",10, "Arial", Green);
ObjectSet("MT4", OBJPROP_CORNER, iCorner);
ObjectSet("MT4", OBJPROP_XDISTANCE, iXDistance);
ObjectSet("MT4", OBJPROP_YDISTANCE, iYDistance);

I could create an object with lines, to the proper place but then I´ll have a problem... The charts will increase/decrease if I zoom :)

And I don´t want to do this on the chart-window!

I hope you understand what I´m trying to do... And someone here able to push me in the right direction...

 

Hi IntraTrade,

1 MB image size !!!. Why don't you just insert the image in here. There's plenty tools when you making comment - I suggest you find the one to insert image(s) and try it.

Use separate window CI like this one https://www.mql5.com/en/articles/1378

 
onewithzachy:

Hi IntraTrade,

1 MB image size !!!. Why don't you just insert the image in here. There's plenty tools when you making comment - I suggest you find the one to insert image(s) and try it.

Use separate window CI like this one https://www.mql5.com/en/articles/1378


Hi,

My image was namned "To Forum.jpg", I change it to "ToForum.jpg"... Now it works...

Maybe I have to make this in another indicator window as a work around. I rather not have my mini-charts om the main window...

 
IntraTrade:


Hi,

My image was namned "To Forum.jpg", I change it to "ToForum.jpg"... Now it works...

Hi IntraTrade,

I forget to add, there's CI in MT called iExposure, write what you want like that.

:D

 
onewithzachy:

Hi IntraTrade,

I forget to add, there's CI in MT called iExposure, write what you want like that.

:D


Hi onewithzachy,

Thanks for the examples. The iExposure uses object that I already do. The first example was massive :) and I will dig deeper to find if there are something that fits...

Do you know if there is a function that keeps track of the user zooming an returns a number between 0-5 (or 1-6), depending of user view?

I looked at all the Windows function and couldn´t find anything...

Then I could write a function that interpolate in pixel-mode, between two points with dots (.) depending of the zoom the user is using. It will work but it might slow down things...

 
IntraTrade:


Hi onewithzachy,

Thanks for the examples. The iExposure uses object that I already do. The first example was massive :) and I will dig deeper to find if there are something that fits...

Do you know if there is a function that keeps track of the user zooming an returns a number between 0-5 (or 1-6), depending of user view?

I had to code my own, you need to find the bar pitch . . pixels between adjacent bars, zoom 5 is 32, zoom 4 is 16, zoom 3 is 8, zoom 2 is 4, zoom 1 is 2 and zoom 0 is 1
Reason: