Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

TsSuperTrend

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    TsSuperTrend

    Can someone add a vertical offset capability for the arrows and cability of selection of the arrow size without having to go thru the code.
    Attached Files

    #2
    Hi rtj4201,

    If you're not able to get a response from the community, consider a NinajScript consultant for this:
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Actually, I looked at the code quickly and added 6 tics to setting. That works. I did not see an arrow size adjustment in the NinjaScript for the DrawArrowUp or DrawArrowDown. How do I adjust the arrow size?

      Comment


        #4
        There's no control for drawing objects' size. As an alternative, some people DrawText() which allows font size control.
        Ryan M.NinjaTrader Customer Service

        Comment


          #5
          rtj4201,

          You can add code that will "offset" any desired object.... Many ways to do this, but the most straightforward might be to

          - add integer field as input....Ex:
          create a Variable
          ... private int _offset = 6;

          - add code to make it modifiable Ex:
          [Description(" ") ]
          [Category("ChartControl") ]
          [Gui.Design.DisplayName ("Offset") ]
          public int Offset
          {
          get {return offset}
          set {offset = Math.Min(15,Math.Max(value,1));}
          }

          - modify the DrawObject command to use (_offset * TickSize)
          instead of a fixed number (such as 6).
          This will let you change the amount of space between the candlestick and the object.

          NOTE: double check the spacing & spelling before you try to copy paste this code. I keyed it fast, may have errors.
          Last edited by photog53; 06-08-2011, 08:51 PM.

          Comment


            #6
            Originally posted by rtj4201 View Post
            Can someone add a vertical offset capability for the arrows and cability of selection of the arrow size without having to go thru the code.

            Ninja does not offer the ability to alter object size...but you can change which object you put on the chart.
            For example...if the "arrow" is too large, then perhaps a small triangle would work better. (Ex: DrawTriangleUp or DrawTriangleDown instead of DrawArrowUp )

            The code syntax is the same for both objects, only the selected object will be different.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            576 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            334 views
            1 like
            Last Post Geovanny Suaza  
            Started by Mindset, 02-09-2026, 11:44 AM
            0 responses
            101 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by Geovanny Suaza, 02-02-2026, 12:30 PM
            0 responses
            553 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            551 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X