• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

how to manage 3rd party DLL and enum reference in exported ninjascript

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

    how to manage 3rd party DLL and enum reference in exported ninjascript

    I have a 3rd-party C++ DLL that exposes numerous methods that take an enum value as a parameter. This DLL also defines those enums.



    The ninjascript incorporates the 'using XXXX' in the header and thus is able to use the enum defined in the 3rd party DLL. There are parameter values to the indicator that use the enum so in keeping with the 3rd party type definitions.

    When i export the indicator as a protected assembly (ie not the source) when the client tries to import the ZIP file numerous error messages are in the trace file stating that 'the type or namespace name 'xxxx' could not be found (are you missing a using directive or an assembly reference).

    When i look at the ZIP file with the created xxx.dll files and the .cs wrapper it is noted in the wrapper the 'using xxx' i defined in the indicator header section is dropped and thus the wrapper code which makes reference to the 3rd party DLL enum doesnt know about the enum type.

    Can you advise on how to manage this situation in delivering this code as a dll to the client. The client does have the 3rd party DLL and assembly loaded and is confirmed in the ninjascript editor and right clicking on the references .. so the 3rd party reference is indeed present.

    any insight greatly appreciated

    thank you

    #2
    Hello soulfx,

    Thank you for your post.

    I will follow up with you in e-mail.
    Patrick H.NinjaTrader Customer Service

    Comment


      #3
      Can anyone who has insight to the original post please disregard the ninja post - this is something else that is being dealt with seperately. Any insight appreciated

      thanks

      Comment


        #4
        Update to this even though no responses were submitted ;
        After a call with Ninja it was determined ( as i sensed but needed confirmation )
        The export assembly process within NT7 has a limitation for this type of export and creating a DLL based on a 3rd party DLL with the protected assembly process.

        The recommended route to handle this is apparently effected by many of the 3rd party ninja partner/vendors is to use something like Visual Studio to manage the build process.

        This i am now investigating : any tips on use of this and to keep simple ie build a DLL from ninja code environment and using a 3rd party DLL to create a DLL with a wrapper .cs file for client to import in the ZIP import process : would be appreciated

        thanks

        Comment


          #5
          Do you have any issue to call a DLL which also have other dependencies? It seems like NT cannot find other dependencies for the target DLL.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by ralett, Today, 07:29 PM
          1 response
          3 views
          0 likes
          Last Post NinjaTrader_Marco  
          Started by bboyle1234, Today, 10:46 PM
          0 responses
          1 view
          0 likes
          Last Post bboyle1234  
          Started by swcooke, Today, 04:29 PM
          0 responses
          4 views
          0 likes
          Last Post swcooke
          by swcooke
           
          Started by bboyle1234, Today, 04:27 PM
          0 responses
          2 views
          0 likes
          Last Post bboyle1234  
          Started by swcooke, Today, 03:31 PM
          2 responses
          11 views
          0 likes
          Last Post swcooke
          by swcooke
           
          Working...
          X