NexusFi: Find Your Edge


Home Menu

 





Problems Converting NT 6.5 indicators to NT7


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one Mindset with 10 posts (1 thanks)
    2. looks_two Fat Tails with 8 posts (10 thanks)
    3. looks_3 Zondor with 7 posts (2 thanks)
    4. looks_4 Big Mike with 5 posts (1 thanks)
      Best Posters
    1. looks_one gregid with 2 thanks per post
    2. looks_two Fat Tails with 1.3 thanks per post
    3. looks_3 eDanny with 0.5 thanks per post
    4. looks_4 Zondor with 0.3 thanks per post
    1. trending_up 56,224 views
    2. thumb_up 26 thanks given
    3. group 16 followers
    1. forum 68 posts
    2. attach_file 16 attachments




 
Search this Thread
  #1 (permalink)
 
Zondor's Avatar
 Zondor 
Portland Oregon, United States
 
Experience: Beginner
Platform: Ninjatrader®
Broker: CQG, Kinetick
Trading: Gameplay Klownbine® Trading of Globex
Posts: 1,333 since Jul 2009
Thanks Given: 1,246
Thanks Received: 2,734

The idea of this thread is to bring together people who are having problems getting their favorite indicators from Ninjatrader 6.5 to work in 7, with those who might be able to fix the problems.

So. tell us what is not working and someone may come along to help you.

If you have found the solutions to any problems that came up when converting an indicator, please post them here.

See the Ninjatrader 7 Code Breaking Changes document, accessible through the NT7 General questions and bug reports thread on the NT forums.


Follow me on X Visit my NexusFi Trade Journal Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
New Section 301 Probes Target 16 Trading Partners -- Tra …
Traders Hideout
Bookmap Global Plus Lifetime + Lifetime Addons For Sale
Platforms and Indicators
February Derivatives Boom -- Every Futures Asset Class S …
Traders Hideout
CME Lists U.S. Election Event Contracts as 2028 Democrat …
Prediction Markets & Event Contracts
Asia Equities Crash Overnight -- Nikkei -5.2%, KOSPI -6. …
Traders Hideout
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Sober Journey With S&P
21 thanks
2026 Jlab journal
10 thanks
Trying to learn Volume and price action correlation
8 thanks
Algo automated / semi-automated trading anyone?
6 thanks
Hello Im new here
5 thanks
  #2 (permalink)
 
Zondor's Avatar
 Zondor 
Portland Oregon, United States
 
Experience: Beginner
Platform: Ninjatrader®
Broker: CQG, Kinetick
Trading: Gameplay Klownbine® Trading of Globex
Posts: 1,333 since Jul 2009
Thanks Given: 1,246
Thanks Received: 2,734

In Ninjatrader 7 there are two additional parameters required. Boolean autoscale goes right after Tag, the first parameter. Usually this should be false. An integer, Y pixel offset, goes right after y. usually this should be 0.

You can find this information in the Ninjatrader 7 Help files. A search for DrawText will get you to the topic.


Follow me on X Visit my NexusFi Trade Journal Started this thread Reply With Quote
  #3 (permalink)
 
Zondor's Avatar
 Zondor 
Portland Oregon, United States
 
Experience: Beginner
Platform: Ninjatrader®
Broker: CQG, Kinetick
Trading: Gameplay Klownbine® Trading of Globex
Posts: 1,333 since Jul 2009
Thanks Given: 1,246
Thanks Received: 2,734


In NT7, rows must be added to a list before attempting to read from or write into those rows. Otherwise, "index out of range" runtime errors are generated.


Follow me on X Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:
  #4 (permalink)
 
lolu's Avatar
 lolu 
Lagos, Nigeria
 
Experience: Intermediate
Platform: NinjaTrader, SierraChart
Trading: Euro Currency & Oil
Frequency: Daily
Duration: Hours
Posts: 2,555 since Jun 2009
Thanks Given: 1,050
Thanks Received: 1,679


Zondor View Post
The idea of this thread is to bring together people who are having problems getting their favorite indicators from Ninjatrader 6.5 to work in 7, with those who might be able to fix the problems.

So. tell us what is not working and someone may come along to help you.

If you have found the solutions to any problems that came up when converting an indicator, please post them here.

See the Ninjatrader 7 Code Breaking Changes document, accessible through the NT7 General questions and bug reports thread on the NT forums.

Zondor,

I've had quite a number of NT6.5 indicators that would not import/compile into NT7Beta. I've been able to import quite a few with a little guidance from the Ninja guys. One of such technique is to copy the .cs file to the required NinjaTrader folder, compile and note the error messages. If the error messages are not many and overwhelming, then the indicator can be tweaked to compile. The Ninjatrader 7 Code Breaking Changes document can also help.

Meanwhile, I'm still not able to import/compile this indicator here. The versions 01 and 02 import/compile without any tweaking, but this version 03 would not import/compile because the "DrawText script command arguments do not conform with NT7 numenclature.

Can you have a look at the indicator above ?

Lolu


Visit my NexusFi Trade Journal Reply With Quote
  #5 (permalink)
 
gregid's Avatar
 gregid 
Wrocław, Poland
 
Experience: Intermediate
Platform: NinjaTrader, Racket
Trading: Ockham's razor
Posts: 649 since Aug 2009
Thanks Given: 320
Thanks Received: 623


lolu View Post

Meanwhile, I'm still not able to import/compile this indicator here. The versions 01 and 02 import/compile without any tweaking, but this version 03 would not import/compile because the "DrawText script command arguments do not conform with NT7 numenclature.

Can you have a look at the indicator above ?

Lolu

Lolu there are 2 additional parameters for DrawText in NT7:
1st is autoscale (true or false)
2nd is pixeloffset (int).

In your case change:
DrawText(objName,"h", objOffset, objVal, objColor, textFont, StringAlignment.Center, Color.Empty, Color.Empty, objectOpacity);

To:

DrawText(objName, false, "h", objOffset, objVal, 0, objColor, textFont, StringAlignment.Center, Color.Empty, Color.Empty, objectOpacity);

Notice where "false" and "0" were added and repeat the same for all other DrawText

Good luck


Reply With Quote
Thanked by:
  #6 (permalink)
 
lolu's Avatar
 lolu 
Lagos, Nigeria
 
Experience: Intermediate
Platform: NinjaTrader, SierraChart
Trading: Euro Currency & Oil
Frequency: Daily
Duration: Hours
Posts: 2,555 since Jun 2009
Thanks Given: 1,050
Thanks Received: 1,679


gregid View Post
Lolu there are 2 additional parameters for DrawText in NT7:
1st is autoscale (true or false)
2nd is pixeloffset (int).

In your case change:
DrawText(objName,"h", objOffset, objVal, objColor, textFont, StringAlignment.Center, Color.Empty, Color.Empty, objectOpacity);

To:

DrawText(objName, false, "h", objOffset, objVal, 0, objColor, textFont, StringAlignment.Center, Color.Empty, Color.Empty, objectOpacity);

Notice where "false" and "0" were added and repeat the same for all other DrawText

Good luck

I did put "false" but it never worked. In fact, I had tweaked quite a few NT6.5 indies with the "false" argument and they worked. Now I'm going to insert the "0".

It works !!!!!!

Thanks.

Lolu


Visit my NexusFi Trade Journal Reply With Quote
  #7 (permalink)
 
eDanny's Avatar
 eDanny 
East Rochester, NY
 
Experience: Intermediate
Platform: NT
Posts: 329 since Jul 2009
Thanks Given: 18
Thanks Received: 425

Those parameters were always available for NT6.5 DrawText() but the code would compile and work without them.


Reply With Quote
Thanked by:
  #8 (permalink)
 
lolu's Avatar
 lolu 
Lagos, Nigeria
 
Experience: Intermediate
Platform: NinjaTrader, SierraChart
Trading: Euro Currency & Oil
Frequency: Daily
Duration: Hours
Posts: 2,555 since Jun 2009
Thanks Given: 1,050
Thanks Received: 1,679


eDanny View Post
Those parameters were always available for NT6.5 DrawText() but the code would compile and work without them.

It never did.

Can you compile this in NT7Beta without those two parameters ? Please let me know.

Lolu


Visit my NexusFi Trade Journal Reply With Quote
  #9 (permalink)
 VictorK 
Milton, On, Canada
 
Experience: Intermediate
Platform: Ninjatrader
Broker: Interactive brokers, Kinetick
Trading: EC, ES, YM, NQ, CL
Posts: 45 since Nov 2009
Thanks Given: 479
Thanks Received: 110

Price line indicator is a very useful indicator that I would like to use with N7 but have not been able to do so. Could someone provide a version to work with N7?
Victor


Reply With Quote
  #10 (permalink)
 
lolu's Avatar
 lolu 
Lagos, Nigeria
 
Experience: Intermediate
Platform: NinjaTrader, SierraChart
Trading: Euro Currency & Oil
Frequency: Daily
Duration: Hours
Posts: 2,555 since Jun 2009
Thanks Given: 1,050
Thanks Received: 1,679



VictorK View Post
Price line indicator is a very useful indicator that I would like to use with N7 but have not been able to do so. Could someone provide a version to work with N7?
Victor

This is what I tweaked and I'm using.

You'll need to copy it to the Ninja "....\bin\Custom\Indicator" folder, then compile it.

Lolu


Attached Files
Elite Membership required to download: PriceLine_Indicator_V_2.cs
Visit my NexusFi Trade Journal Reply With Quote
Thanked by:




Last Updated on October 24, 2014


© 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