PDA

View Full Version : NT restart required when referencing an external dll


astrolobe
11-29-2007, 08:50 PM
I call some methods from a custom dll. It compiles without a problem, except when I add the strategy to the chart, non of the expected behaviour occurs, i.e. the strategy code does not do anything, and no errors occur. Also intellisense does not work in the Strategy for the new classes and methods in the custom dll.

To make it work, all I have to do is shut down NT (beta 4) and restart it. I go into my program and recompile for good measure...and it works as it should.

A seperate issue: Are the references for each strategy accumalative? If I have two strategies A and B, and each strategy requires its own different reference to a dll, eg. dll_1 and dll_2, then when compiling Strategy A, I am forced to reference the dll that is used for Strategy B as well. If I don't, then I get a compilation error for Strategy B, even though I am trying to compile strategy A.

NinjaTrader_Dierk
11-29-2007, 10:08 PM
>> I call some methods from a custom dll
Unfortunately referencing external DLLs is beyond of what we can support (although it works). Please contact a NinjaScript consultant if you need further assistance: http://www.ninjatrader.com/webnew/partners_onlinetrading_NinjaScript.htm

astrolobe
11-29-2007, 10:59 PM
I understand that external dll's are not supported. However, you might want these issues raised, especially as the evidence is pointing towards a problem in NT? This may be the effect of some other problem, that you may want to fix.
Let me know if you would prefer that we don't raise dll issues.

NinjaTrader_Dierk
11-29-2007, 11:01 PM
Unfortunately referencing external DLLs is beyond of what we can support. If you feed there is a problem with NT itself: please isolate without usage of any external DLL and let us know.

Jappenzeller
03-11-2008, 06:54 PM
Did you ever figure out a fix for this? I'm having the same issue.

astrolobe
03-18-2008, 05:59 PM
I still use the workaround. My understanding is that when you reference a dll, not just in NT, but generally, whatever is referencing the dll, puts a lock on the dll file. If you create a new version of a dll and try to overwrite the existing one, then you receive the message that the existing dll cannot be overwritten because it is in use. That is why I have to shut down NT (to release the lock), so that I can overwrite the existing dll with a newer version.