Problem with DRAWTEXT not always working

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #204489 quote
    JayD
    Participant
    Junior

    A simple code just to label Ichimoku lines from weekly and monthly time frames on a Daily Time Frame
    All the labels show up except for the SSB Monthly label. It is surely a stupid error that is staring at me but I can not see it.

    If anyone could help it would be greatly appreciated.

    Thank you.

    // Write Kijun and SSB Weekly and Monthly Labels when using Daily Time Frame
    DEFPARAM DRAWONLASTBARONLY=true
    // Ichimoku Weekly
    TIMEFRAME(Weekly)
    KijunWeekly=KijunSen[9,26,52]
    SSBWeekly =SenkouSpanB[9,26,52]
    // Ichimoku Monthly
    TIMEFRAME(Monthly)
    KijunMonthly=KijunSen[9,26,52]
    SSBMonthly =SenkouSpanB[9,26,52]
    TIMEFRAME(Daily)
    DRAWTEXT("Kijun W",barindex+2, KijunWeekly,SansSerif,Bold,12) COLOURED(0,0,255)
    DRAWTEXT("SSB W",barindex+2, SSBWeekly,SansSerif,Bold,12) COLOURED(64,192,255)
    DRAWTEXT("Kijun M",barindex+4, KijunMonthly,SansSerif,Bold,12) COLOURED(0,0,255)
    DRAWTEXT("SSB M",barindex+2, SSBMonthly,SansSerif,Bold,12) COLOURED(64,192,255)
    
    RETURN
    #204492 quote
    robertogozzi
    Moderator
    Master

    Do you have enough units on your chart (3K to 5k)?

    JayD thanked this post
    #204494 quote
    robertogozzi
    Moderator
    Master

    I moved the topic from the French forum.

    Use the correct forum, please.

    Thank you 🙂

    JayD thanked this post
    #204498 quote
    JS
    Participant
    Senior

    It is there but as Roberto says “use more units”…

    JayD thanked this post
    #204503 quote
    JayD
    Participant
    Junior
    Sorry. My bad.
    #204518 quote
    JayD
    Participant
    Junior
    Thank you Roberto and JS. Increased the units to 1200 and it now shows up.
    JS thanked this post
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.

Problem with DRAWTEXT not always working


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
JayD @jayd Participant
Summary

This topic contains 5 replies,
has 3 voices, and was last updated by JayD
3 years, 2 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 11/19/2022
Status: Active
Attachments: 2 files
Logo Logo
Loading...