NexusFi: Find Your Edge


Home Menu

 





NT8 Strategy draw HorizontalLine on Chart


Discussion in NinjaTrader

Updated
    1. trending_up 2,508 views
    2. thumb_up 0 thanks given
    3. group 2 followers
    1. forum 3 posts
    2. attach_file 0 attachments




 
Search this Thread
  #1 (permalink)
 hyperscalper 
boise idaho
 
Experience: Advanced
Platform: NinjaTrader C# Custom
Broker: NinjaTrader LeeLoo Rithmic
Trading: Nasdaq Futures NQ/MNQ
Posts: 314 since Apr 2020
Thanks Given: 15
Thanks Received: 541

Hi.

Can't figure out how a Strategy draws a HorizontalLine
on a host Chart.

Indicators seem to do so easily; but I can't
find anything for a Strategy.

Maybe there is no HorizontalLine; just Line and
I need to specify from and to coordinates...? That
might be it. But HorizontalLine is supposed to exist,
although I think it may be NT7 documentation, miscategorized
as NT8 documentation here:
https://ninjatrader.com/support/helpGuides/nt8/?draw_horizontalline.htm

Anybody got a simple code snippet?

hyperscalper


Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Peace Deal Forward Curve: May 22%, June 51%, December 81 …
Prediction Markets & Event Contracts
Prediction Markets Lock Fed Pause at 99pct for April 29 …
Prediction Markets & Event Contracts
Iran Airspace Contract Surges to 33.5% as Project Freedo …
Prediction Markets & Event Contracts
CFTC Workforce Shrinks 24% to 15-Year Low While Predicti …
Traders Hideout
Kraken Becomes First US Digital Asset Bank With Direct F …
Cryptocurrency
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Sober Journey With S&P
24 thanks
2026 Jlab journal
10 thanks
Algo automated / semi-automated trading anyone?
6 thanks
Lady Vols Primer: Trading Volatility Journal
6 thanks
Trying to learn Volume and price action correlation
5 thanks
  #2 (permalink)
 
Jasonnator's Avatar
 Jasonnator 
Denver, Colorado United States
 
Experience: Intermediate
Platform: NT8 + Custom
Broker: NT Brokerage, Kinetick, IQFeed, Interactive Brokers
Trading: ES
Posts: 158 since Dec 2014
Thanks Given: 40
Thanks Received: 166

Drawing tools are the same between indicators and strategies because both use the NinjaTrader.NinjaScript.DrawingTools namespace.

documentation with numerous examples.


Reply With Quote
  #3 (permalink)
 hyperscalper 
boise idaho
 
Experience: Advanced
Platform: NinjaTrader C# Custom
Broker: NinjaTrader LeeLoo Rithmic
Trading: Nasdaq Futures NQ/MNQ
Posts: 314 since Apr 2020
Thanks Given: 15
Thanks Received: 541



Jasonnator View Post
Drawing tools are the same between indicators and strategies because both use the NinjaTrader.NinjaScript.DrawingTools namespace.

documentation with numerous examples.

Yeah, that's what I thought; until I couldn't figure it out. Indicators seem to be
much more prevalent; but nobody has yet shown me a Strategy that does
it.
hyperscalper


Started this thread Reply With Quote
  #4 (permalink)
 hyperscalper 
boise idaho
 
Experience: Advanced
Platform: NinjaTrader C# Custom
Broker: NinjaTrader LeeLoo Rithmic
Trading: Nasdaq Futures NQ/MNQ
Posts: 314 since Apr 2020
Thanks Given: 15
Thanks Received: 541

PROBLEM RESOLVED

This was a Development Environment override of the Draw function
in Visual Studio, by a "partial class" definition in the namespace
NinjaTrader.NinjaScript.DrawingTools which did not have
Draw.HorizontalLine defined, of course; in my local Documents
filesystem.

So, it's a Visual Studio Dev environment unintended class override
which was making it impossible to see the Draw.HorizontalLine

Ya learn something every day !!! I'm a Java programmer with Eclipse;
and haven't spent the required years with Visual Studio C# !!

hyperscalper


Started this thread Reply With Quote




Last Updated on October 8, 2020


© 2026 NexusFi®, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Downloads - Top
no new posts