Draw lines and areas. Label lines

Forums ProRealTime English forum ProBuilder support Draw lines and areas. Label lines

Viewing 6 posts - 1 through 6 (of 6 total)
  • #254599

    Hello everyone, I have been trying to build an indicator for lines and zones derived from the day’s opening price. I am able to draw lines, but I am unable to display the price value of the line on the right side of the line. I also haven’t been able to figure out how to fill in the zones cleanly. Does anyone have a simple trick for how to do this?

    Thx in advance…

    Best regards,

    Björn

    #254603

    Use DrawText, like this example of your first line plotted:

    more details at https://www.prorealcode.com/documentation/drawtext/.

     

     

    2 users thanked author for this post.
    #254604

    see the attached picture.

     

    1 user thanked author for this post.
    #254606

    Thank you for the very fast reply.

    The line is now labeled, but each finished candle generates a new number.
    Can this number, which is determined from the opening price in the morning, be displayed only once for the entire day?

    Regards, Björn

    #254616

    Add this line at the very beginning of your code:

    but this will remove all previous segments and rectangles.

    If this is fine for you, then it’s the best solution, otherwise you will need to use two copies of the same indicator, one that draws all the segments and rectangles (it’s the one you are using now), the other one is the same, but will only plot the text at each new bar, which is this one:

    add both the indicators on your chart (using different names).

     

     

     

    1 user thanked author for this post.
    #254617

    Thank you very much.
    I will take the way with two copies of the Indi.
    This will work for me.

    Best regards,
    Björn

    1 user thanked author for this post.
Viewing 6 posts - 1 through 6 (of 6 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login