How to start background process in NT 8 when Control Panel start? - NinjaTrader Programming | futures io social day trading
futures io futures trading


How to start background process in NT 8 when Control Panel start?
Updated: Views / Replies:105 / 4
Created: by vantojo Attachments:0

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors Ė all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you donít need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Reply
 
Thread Tools Search this Thread
 

How to start background process in NT 8 when Control Panel start?

  #1 (permalink)
Elite Member
Neuquen, Argentina
 
Futures Experience: Intermediate
Platform: Ninja
Favorite Futures: CL, TF, 6S, NG, sometimes GC
 
Posts: 195 since Jul 2012
Thanks: 25 given, 39 received

How to start background process in NT 8 when Control Panel start?

Hello,

Does anyone have code samples of how to write a NT 8 AddOn that will start with Ninjatrader Control Panel?

I now have background processes running OK in NT7. But never really liked the restrictions placed by the NT 7 architecture for such processing requirements.

One process is is for internal/external messaging via MSMQ and XMPP servers the other is a one time (load internal static lists from SQL). Neither connects to a data stream from the broker.

If someone has a code sample I can study it will save me hours of wading through documentation looking for the answer.

Many Thanks!

Reply With Quote
 
  #2 (permalink)
Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

 
  #3 (permalink)
Elite Member
Neuquen, Argentina
 
Futures Experience: Intermediate
Platform: Ninja
Favorite Futures: CL, TF, 6S, NG, sometimes GC
 
Posts: 195 since Jul 2012
Thanks: 25 given, 39 received

first look


at first look it seems this may work...

probably OnWindowsCreated() in an AddOn to hook the Control Panel startup .... ??

will post if I get it working

Reply With Quote
 
  #4 (permalink)
Administrator: Retired Backtester
 Vendor: speedytradingservers.com 
Rennes France
 
Futures Experience: Advanced
Platform: NinjaTrader
Broker/Data: IB/Kinetick
Favorite Futures: Futures
 
sam028's Avatar
 
Posts: 3,366 since Jun 2009
Thanks: 3,570 given, 3,982 received

Why not save a workspace with this AddOn then use this workspace by default?

Success requires no deodorant! (Sun Tzu)
Reply With Quote
 
  #5 (permalink)
Elite Member
Neuquen, Argentina
 
Futures Experience: Intermediate
Platform: Ninja
Favorite Futures: CL, TF, 6S, NG, sometimes GC
 
Posts: 195 since Jul 2012
Thanks: 25 given, 39 received

success....

Ok, with some hacking I have it working...it is simple once I could get myself out of the way.... :-)

The task at hand was to load SQL database parameters into public static variables during startup. These then configure my strategies and indicators. In NT7 I had to kludge this, but in NT8 it actually feels like the architecture can accommodate this easily.

I moved the public static variables into a non-ninja namespace/class in CS file in AddOns. The Ninja editor will open it and make changes, save it back just like it was an AddOn.

And, then it is relatively simple....in an AddOn...to load data from SQL tables during the Ninja startup

protected override void OnStateChange()
{
if (State == State.SetDefaults)
{
}
else if (State == State.Configure)
{
t1 = new Thread (new ThreadStart (LoadSQLData));
t1.Start();
}
}

I started another thread so that the startup process was not encumbered waiting for the database login, access, etc.

Reply With Quote

Reply



futures io > > > > > How to start background process in NT 8 when Control Panel start?

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)

Linda Bradford Raschke: Reading The Tape

Elite only

Adam Grimes: TBA

Elite only

NinjaTrader: TBA

January

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Hook when NT 7 Control Panel Launches? vantojo NinjaTrader Programming 3 November 23rd, 2017 02:52 PM
Turn off global sim at start up in NT wldman NinjaTrader 6 January 6th, 2015 01:43 PM
Where do I start???!!! birkmann3 Beginners and Introductions 37 February 21st, 2014 01:24 PM
Change Font on the control panel in Ninja Trader Silver Dragon NinjaTrader Programming 2 June 3rd, 2012 02:40 AM
SMA with Discretionary Start Time and Start Date for MC tradernovice EasyLanguage Programming 4 July 29th, 2011 07:50 PM


All times are GMT -4. The time now is 12:29 AM.

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
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.
no new posts
Page generated 2017-12-10 in 0.06 seconds with 18 queries on phoenix via your IP 54.90.207.75