![]() |
This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com
|
|||||||
| Automated Trading Support for automated trading systems using NinjaScript. Support for our ATI (Automated Trading Interface) used to link an external application such as TradeStation and eSignal to NinjaTrader. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Certified NinjaScript Consultant
|
I keep getting the following error message on the Ninja Log when I use the DLL interface, apparently only when using mypaper IB trading account but not when I use my live IB trading account.
Code:
IB.Globals.MessageLoop msg='12': Specified argument was out of the range of valid values. Parameter name: Index was out of range. Must be non-negative and less than the size of the collection. IB.Globals.MessageLoop msg='12': Specified argument was out of the range of valid values. Parameter name: Index was out of range. Must be non-negative and less than the size of the collection. IB.Globals.MessageLoop msg='12': Specified argument was out of the range of valid values. Parameter name: Index was out of range. Must be non-negative and less than the size of the collection. Regards, Whitmark |
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: Mar 2005
Location: Amsterdam, The Netherlands
Posts: 2,042
Thanks: 0
Thanked 3 times in 3 posts
|
Hi Whitmark,
Can you reset your Simulator and then try again. Go to Tools--> Options--> Simulator tab--> Reset Vince
Vincent
NinjaTrader Customer Service |
|
|
|
|
|
#3 |
|
Certified NinjaScript Consultant
|
Hi Vince,
Thanks for the quick response. Tried that again and no luck . . . any other suggestions? Regards, Whitmark |
|
|
|
|
|
#4 |
|
Administrator
Join Date: Nov 2004
Location: Denver, CO, USA
Posts: 11,163
Thanks: 6
Thanked 45 times in 32 posts
|
Hi Whitmark,
This problem is related to the depth of market information being sent from the IB demo system. It appears that TWS is not sending correct depth position information to us which generates these errors. I am curious if this happens if you just use the SuperDOM? Ray
Ray
NinjaTrader Customer Service |
|
|
|
|
|
#5 |
|
Certified NinjaScript Consultant
|
It would appear to work fine on the SuperDom and does not seem to be a critical error per se on the ATI as I can tell yet. What next?
Regards, Whitmark |
|
|
|
|
|
#6 |
|
Administrator
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
|
To clarify:
- as you have DOM open and no ATI running, all is fine - as you have DOM open an ATI running, problem is there - as you only have ATI running and no DOM, all is fine Curious: What do you trigger trhough ATI? A lot of activity which might load the CPU and cause TWS to get out of sync?
Dierk
NinjaTrader Customer Service |
|
|
|
|
|
#7 |
|
Certified NinjaScript Consultant
|
I always have the DOM up whenI run theATIso I will need to test with the DOM closed. Also, the error seems appear when the DOM is up and regardless of whether the ATI is activated or not, but I will need to reconfirm this.
Regarding what Iam pushing through theATI, its only end of bar processingof the Command function for PLACE, CANCELALLORDERS, CLOSEPOSITION, REVERSEPOSITION and a checkof the MarketPosition functionmake sure its flat under certain conditionsbefore I place a new order, so I suspect the load is light. Let me experiment tomorrow more to see if I can pin down the symptoms and report back. Regards, Whitmark |
|
|
|
|
|
#8 |
|
Administrator
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
|
Great, also:
- which instrument do you have on the DOM? - is that the same instrument you trade thru ATI?
Dierk
NinjaTrader Customer Service |
|
|
|
|
|
#9 |
|
Certified NinjaScript Consultant
|
When using the IBpaper trading account, the error message only occurswhen I have the dynamic DOM up (I am not subscribed to the static DOM) regardless of whether the ATI is activated. Please see attached. I am testing the IB 'ER2 12-06' symbolon the Both the ATI andDOM concurrently.
When a manual order isplaced on the DOM the error persists before the entry order is filled, after the entry order is filled, and after the trade is closed out. Likewise, when an ATI order is placed, the error appears before, during, and after a position is taken while the dynamicDOM is up. It doesn't appear the error impacts proper fill, targets, stops, etc from what I can tell. Hope that helps. Let me know if you need additional testing to resolve this. Regards, Whitmark |
|
|
|
|
|
#10 |
|
Administrator
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
|
I'm on a loss. Live account works fine. We don't have paper trade account access though. As stated below, likely an issue on TWS's end.
Dierk
NinjaTrader Customer Service |
|
|
|
|
|
#11 |
|
Certified NinjaScript Consultant
|
Setting up a paper trading account is as easy as making a selection in the IB Account Manager . . . very easy to do and thepaper trading account'sfill model is as good, IMO, as the Sim101 sim account in Ninja. Check it out, its a free feature.
Regards, Whitmark |
|
|
|
|
|
#12 |
|
Administrator
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
|
I can acknowledge, that there is a problem with inconsistent L2 data coming from TWS paper trade account. However, this is out of our control.
I suggest using your IB live account and trade against Sim101.
Dierk
NinjaTrader Customer Service |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|