Move text label to left

Back to topics list To post a new topic, please log in or register
avatar
87
FxTrader_ 2016.05.05 09:38
 

Hi,

Is it possible to move the text label to the left side of screen.

   
         if (Monthly==true)
          {
           TimeToStr(CurTime());
           ObjectCreate("PivotLine", OBJ_HLINE,0, CurTime(),MN1_priceH);
           ObjectSet("PivotLine", OBJPROP_COLOR, Magenta);
           ObjectSet("PivotLine", OBJPROP_STYLE, STYLE_DOT);
           ObjectSet("PivotLine",OBJPROP_BACK,1);
         
          if(ObjectFind("PivotLabel") != 0)
           {
            ObjectCreate("PivotLabel", OBJ_TEXT, 0, Time[0], MN1_priceH);
            ObjectSetText("PivotLabel", ("Monthly High"), 8, "Arial", Magenta);
           }
          else
           {
            ObjectMove("PivotLabel", 0, Time[0], MN1_priceH);
           }
         ObjectsRedraw();


Any help will be appreciated.


avatar
Moderator
3206
angevoyageur 2016.05.05 12:49 #
 
FxTrader_:

Hi,

Is it possible to move the text label to the left side of screen.


Any help will be appreciated.


A text object (OBJ_TEXT) is linked to time (chart). If you want to place a label/text at a given position use a OBJ_LABEL.
avatar
8
awran5 2016.05.08 08:25 #
 
angevoyageur:
A text object (OBJ_TEXT) is linked to time (chart). If you want to place a label/text at a given position use a OBJ_LABEL.


Or you can reduce some time (in seconds) from Time[0]

Time[0]-3600 // 1 Hour back


avatar
Moderator
3206
angevoyageur 2016.05.08 10:03 #
 
awran5:


Or you can reduce some time (in seconds) from Time[0]


And your text will move on every new candle.
avatar
69
Tecuciztecatl 2016.05.08 17:34 #
 

The left bar on the screen is:
CHART_FIRST_VISIBLE_BAR — Number of the first visible bar in the chart. Indexing of bars is the same as for timeseries.

Back to topics list  

To add comments, please log in or register