Using ZeroMQ within Ninjatrader 7 - NinjaTrader Programming | futures io social day trading
futures io futures trading


Using ZeroMQ within Ninjatrader 7
Updated: Views / Replies:629 / 6
Created: by Jack Larkin 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
 

Using ZeroMQ within Ninjatrader 7

  #1 (permalink)
Trading Apprentice
Toronto Ontario
 
Futures Experience: Advanced
Platform: Firm's OMS, fxTrade, MetaTrader
Broker/Data: Equities: Through my work (firm.) Spot FX: Oanda, Pepperstone
Favorite Futures: US / Canadian Stocks, Spot FX
 
Posts: 23 since Jan 2013
Thanks: 3 given, 38 received

Using ZeroMQ within Ninjatrader 7

Having a dilly of a pickle trying to use ZeroMQ from within a Ninjatrader script/indicator. I'm a python programmer and have only just started dabbling with C# and NT in general.

Where I've gotten so far:

- Taken the C# release/bindings for ZeroMQ, and placed the approperate DLL files in the NT's bin/Custom folder. This includes the main ZeroMQ.DLL file and two sub directories as part of the release folder within the download from this link:
https://github.com/zeromq/clrzmq4/releases

- Added the ZeroMQ.DLL file as a reference within Ninjatrader.

- Included a "using ZeroMQ;" line. This is accepted without error.

- Wrote in some C# ZeroMQ code into an indicator, which saves and compiles without issue. That is to say, NT seems to get the class references and namespace from the DLL file just fine.

- Added said indicator onto a chart, which starts but fails to plot anything. In NT's output window I get this error:

"""Failed to call method 'Initialize' for indicator 'MyCustomIndicator': Could not load file or assembly 'ZeroMQ, Version=4.1.0.21, Culture=neutral, PublicKeyToken=4a9630883fd6c563' or one of its dependencies. The system cannot find the file specified."""

So it appears to be failing on a dependency somewhere outside the initial DLL import.

Has anyone done this before? Where am I going wrong?

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
Omer עומר / Israel י
 
Futures Experience: Master
Platform: NinjaTrader, Proprietary,
Broker/Data: Ninjabrokerage/IQfeed + Synthetic datafeed
Favorite Futures: 6A, 6B, 6C, 6E, 6J, 6S, ES, NQ, YM, AEX, CL, NG, ZB, ZN, ZC, ZS, GC
 
rleplae's Avatar
 
Posts: 2,501 since Sep 2013
Thanks: 1,706 given, 3,706 received
Forum Reputation: Legendary


What .net version is the library dependant on ?

1) I believe there is a limitation, that a DLL you load into the NT7 address space, can not be more recent than .Net framework 3.5. Could that be the issue you are running into ?

2) It is possible that the DLL you have loaded in NT7, at run-time is needed a number of other DLL's (system/third party) that are not found. Two ways to find that out 1) make a small c# stub outside NT and use the same DLL 2) use a tool like filmon to see what exception it is giving when looking for a specific DLL

good luck !

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,573 given, 3,982 received

@Jack Larkin, did you build it from the source using .Net 3.5 and not 4.0 which is the default target?

Success requires no deodorant! (Sun Tzu)
Reply With Quote
 
  #5 (permalink)
Trading Apprentice
Toronto Ontario
 
Futures Experience: Advanced
Platform: Firm's OMS, fxTrade, MetaTrader
Broker/Data: Equities: Through my work (firm.) Spot FX: Oanda, Pepperstone
Favorite Futures: US / Canadian Stocks, Spot FX
 
Posts: 23 since Jan 2013
Thanks: 3 given, 38 received


sam028 View Post
@Jack Larkin, did you build it from the source using .Net 3.5 and not 4.0 which is the default target?

Not building it at all, just taking the binary release from the package provided in that link.

Another poster in another forum mentioned that NT7 is based on .NET 3.5, yet this package is for .NET 4.. I think that might be the source of the issue and I'm digging deeper.

Reply With Quote
 
  #6 (permalink)
Elite Member
Omer עומר / Israel י
 
Futures Experience: Master
Platform: NinjaTrader, Proprietary,
Broker/Data: Ninjabrokerage/IQfeed + Synthetic datafeed
Favorite Futures: 6A, 6B, 6C, 6E, 6J, 6S, ES, NQ, YM, AEX, CL, NG, ZB, ZN, ZC, ZS, GC
 
rleplae's Avatar
 
Posts: 2,501 since Sep 2013
Thanks: 1,706 given, 3,706 received
Forum Reputation: Legendary


Jack Larkin View Post
Not building it at all, just taking the binary release from the package provided in that link.

Another poster in another forum mentioned that NT7 is based on .NET 3.5, yet this package is for .NET 4.. I think that might be the source of the issue and I'm digging deeper.

You will not be able to install a .NET .4 depedant package,
i am sure about that,
i have run into that issue before

Two options :
1) take the source and compile for 3.5 (provided that the source does not use specifics
that only exist in 4.0
2) find a binary that is compiled for the target platform 3.5 or lower

Reply With Quote
 
  #7 (permalink)
Trading Apprentice
Toronto Ontario
 
Futures Experience: Advanced
Platform: Firm's OMS, fxTrade, MetaTrader
Broker/Data: Equities: Through my work (firm.) Spot FX: Oanda, Pepperstone
Favorite Futures: US / Canadian Stocks, Spot FX
 
Posts: 23 since Jan 2013
Thanks: 3 given, 38 received

A user on EliteTrader got me in the right direction. It totally was the NT7 using .NET 3.5 being incompatible with the .NET 4.0 compiled ZMQ binary I was using.

I cut over to NT8, which was built using .NET 4.0, and after some minor troubleshooting I got it working as expected.

Details here:
http://www.elitetrader.com/et/index.php?threads/using-zeromq-from-within-ninjatrader-assistance-bitte.299842/

(If linking to another trading forum is a no-no, mods feel free to delete the link.. just posting what worked and how I resolved it.)

Reply With Quote

Reply



futures io > > > > > Using ZeroMQ within Ninjatrader 7

Thread Tools Search this Thread
Search this Thread:

Advanced Search



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

Jigsaw Trading: TBA

Elite only

FuturesTrader71: TBA

Elite only

NinjaTrader: TBA

Jan 18

RandBots: TBA

Jan 23

GFF Brokers & CME Group: Futures & Bitcoin

Elite only

Adam Grimes: TBA

Elite only

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Embed ninjatrader chart to excel - NinjaTrader to Excel Minds NinjaTrader 2 April 13th, 2016 07:01 PM
Webinar: NinjaTrader Brokerage and NinjaTrader 8 (NT8) discussion Big Mike NinjaTrader 8 July 2nd, 2014 09:17 PM
Can NinjaTrader data be stored other than \My Documents\NinjaTrader 6.5 tc12357 NinjaTrader 4 December 15th, 2009 02:55 PM


All times are GMT -4. The time now is 06:09 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-15 in 0.10 seconds with 19 queries on phoenix via your IP 107.20.115.174