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

How to create a library

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

    #16
    Originally posted by ivb73077 View Post
    Jesse,

    I have created several UserDefinedMethod partial classes and integrated them with my strategy files. Everything is working perfectly.

    I now wish to share these files with my colleague but came across a post stating that UserDefinedMethod .cs files cannot be exported.

    I suspect I can circumvent this limitation by simply sending the .cs files and having my colleague copy them to the //NinjaTrader7/bin/Custom/Strategy folder. Do you know if this approach would work? Am I missing anything?

    Thank you.
    Rename the file that holds your partial classes. In other words, do not use UserDefinedMethods.cs as the file name.

    Comment


      #17
      Thank you.

      I had already done this as there are several such files I have created. Seems what I needed to do was package all the new partial class files together into a single ZIP file.

      I wonder if I need to include all these files with every strategy file I export? Or will it be sufficient to export the partial class ZIP file?

      Comment


        #18
        Originally posted by ivb73077 View Post
        Thank you.

        I had already done this as there are several such files I have created. Seems what I needed to do was package all the new partial class files together into a single ZIP file.

        I wonder if I need to include all these files with every strategy file I export? Or will it be sufficient to export the partial class ZIP file?
        If the Strategy uses any methods or variables defined in a partial class, the referenced partial class file will have to be exported with the Strategy.

        Comment


          #19
          Makes sense.

          I just wasnt sure if i needed to export all the partial classes every time i export a strategy that utilizes them or simply export once and allow each strategy exported thereafter to use the partial classes (as all strategies will use the same set of partial classes).

          thanks.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by grazz, 07-28-2017, 06:11 PM
          26 responses
          6,846 views
          0 likes
          Last Post SpockTrader  
          Started by frslvr, Today, 11:36 AM
          4 responses
          13 views
          0 likes
          Last Post NinjaTrader_ChelseaB  
          Started by tkaboris, 07-15-2024, 01:42 PM
          13 responses
          25 views
          0 likes
          Last Post NinjaTrader_Jesse  
          Started by richard_w, Today, 12:33 PM
          1 response
          6 views
          0 likes
          Last Post NinjaTrader_Gaby  
          Working...
          X