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!
See more
See less

Partner 728x90

Collapse

Help with compiled assembly

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Help with compiled assembly

    Hello,

    I am trying to add Vendor Licensing to my strategy but I am not familiar with using a default constructor. The strategy will compile, export and import ok, but when I go to add the strategy to a chart, I get an error.... Any guidance you can provide would be appreciated. Here is part of the code... #region Using declarations


    I am getting exactly the same error. This is my own assembly. I made sure there is no underscore in the name. I have NinjaTrader 8.1.... this was never an issue in NinjaTrader 8.0.....

    I prefer to keep code compiled as assembly in VMs. Out of curiosity I manually copied the files to VM, all compiled without an issue and I was able to use indicators/strategies. But when the same files are put into protected assembly this issues manifest. The import goes in without an issue, but when I try to access indicators same exact error is shown.

    Thanks,
    redduke
    Last edited by NinjaTrader_Jesse; 11-10-2023, 01:59 PM.

    #2
    Hello RedDuke,

    It looks like the previous user solved this by making sure the vendor information in the VendorLicense check was valid. For your situation you would want to follow the same steps that were posted to reply # 2 and check what part of your code is having an error. If its a VendorLicense line of code you would need to make sure you have used the correct values.
    JesseNinjaTrader Customer Service

    Comment


      #3
      Hi Jesse,

      This is my own code. I use protected assembly as security feature to deploy my own source code. There is no vendor involved. I just export code from my development laptop and import into Ninja running on VM. This is the first time I attempted this in Ninja 8.1.7. How can I see where the error is? The code compiles are run normally when scripts are just copied directly.
      Thanks,
      redduke

      Comment


        #4
        Hello RedDuke,

        As it seems this is unrelated to the thread you posted in i went ahead and moved this into a new thread.

        The easiest way to check what problem is happening would be to comment out your custom code and export only the structure of the script. For example if this was an indicator you would comment everything out besides OnStateChange and OnBarUpdate, just the custom code you added. Then export the script and test that it works to import and use it. If you dont get an error you can do the same tests again but uncomment some of the code. Once you do this and get the error the last uncommented code would relate to the problem.


        JesseNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by JoMoon2024, Today, 06:56 AM
        0 responses
        6 views
        0 likes
        Last Post JoMoon2024  
        Started by Haiasi, 04-25-2024, 06:53 PM
        2 responses
        17 views
        0 likes
        Last Post Massinisa  
        Started by Creamers, Today, 05:32 AM
        0 responses
        5 views
        0 likes
        Last Post Creamers  
        Started by Segwin, 05-07-2018, 02:15 PM
        12 responses
        1,786 views
        0 likes
        Last Post Leafcutter  
        Started by poplagelu, Today, 05:00 AM
        0 responses
        3 views
        0 likes
        Last Post poplagelu  
        Working...
        X