Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Calling DLL from strategy
Collapse
X
-
Calling DLL from strategy
I am using version 7. I am attempting to call a DLL function from my strategy. I have added all of the relevant DLL's in the bin/custom directory. I have referenced the DLL and the strategy builds successfully. The initialisation fails with an error: Could not load file or assembly ... The system cannot find the file specified. A similar exercise in version 6.5 worked. Are there any changes in the new release that would cause this error? Is there a way of finding which file is missing?Tags: None
-
Originally posted by brucieW View PostI am using version 7. I am attempting to call a DLL function from my strategy. I have added all of the relevant DLL's in the bin/custom directory. I have referenced the DLL and the strategy builds successfully. The initialisation fails with an error: Could not load file or assembly ... The system cannot find the file specified. A similar exercise in version 6.5 worked. Are there any changes in the new release that would cause this error? Is there a way of finding which file is missing?
-
I tried creating a simple class library DLL with only one API, added it to the reference, added using statement and call to API in strategy code. All compiles cleanly but still same problem when I run a backtest. It can't find the DLL. This new class library doesn't reference any other DLL but Ninja is still unable to load it.
Comment
-
I am having the exact same problem; has there been any resolution of this issue?
I even tried changing the constructor in the dll and then recopying it to the bin->Custom directory. When I restarted NT, I got the message I had a programming error in one of my strategies. This was now correct since the old new() statement was no longer valid.
I corrected the error by adhering to the new constructor and yet the same "can't find..." message when trying to use the dll. NT can find the assembly such that it can give me a compile error but can't load it because it can't find it.
I am likely doing something very simple incorrectly but this is how I would load a dll in a non NinjaTrader project.
Best Regards,
Scott
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by PhillT, 04-19-2024, 02:16 PM
|
3 responses
14 views
0 likes
|
Last Post
by mangel2000
Today, 03:04 AM
|
||
Started by TraderBCL, Today, 02:37 AM
|
0 responses
1 view
0 likes
|
Last Post
by TraderBCL
Today, 02:37 AM
|
||
Started by mangel2000, Today, 02:23 AM
|
0 responses
6 views
0 likes
|
Last Post
by mangel2000
Today, 02:23 AM
|
||
Started by mangel2000, Today, 01:30 AM
|
0 responses
14 views
0 likes
|
Last Post
by mangel2000
Today, 01:30 AM
|
||
Started by Doxxxx, Today, 01:24 AM
|
0 responses
5 views
0 likes
|
Last Post
by Doxxxx
Today, 01:24 AM
|
Comment