• 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

Duplicate Method Names

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

    Duplicate Method Names

    Hi,

    I am getting the duplicate method names error when importing my custom indicator.

    I have scanned the forums and the suggested fixes have not helped me, but I can add that -

    - The error occurs whether or not I use CliSecure to encrypt
    - I have tried importing my indicator into a fresh and clean installation of NT, with no custom source files installed
    - I can copy the source file to the fresh NT installation and compile it without error
    - the source file includes one public enum
    - the source file uses the VOL.cs file which it says it needs to include when it exports

    Any suggestions?

    Thanks,
    Will.

    #2
    Will,

    Thank you for your posting.

    I believe this is because of the public enum that you are calling. If you are calling that public enum from any other indicator NinjaTrader will see this as a duplicate method error.

    Is this being called within the Indicator class or outside of it?
    Cal H.NinjaTrader Customer Service

    Comment


      #3
      Hi Cal,

      I doubt that there is another indicator with the same name because I am trying to install it on a clean installation of NT.

      It is declared outside the namespace, and used only within the indicator.

      note that it compiles and run's fine, its only when I export it and then try to import it that the problem occurs.

      Will.

      Comment


        #4
        Will,

        Are you importing the system on the same computer you have the source code?
        Cal H.NinjaTrader Customer Service

        Comment


          #5
          No, its a different computer with a fresh install of NT.

          Comment


            #6
            Will,

            Can you send me the exported zip folder, so that I may test it on my end?

            You can send the folder to support[at]ninjatrader[dot]com with ATTN Cal in the subject and a reference to this thread in the body.

            Thank you for your patience.
            Cal H.NinjaTrader Customer Service

            Comment


              #7
              Was a solution found for this? Is there a particular coding practice that causes this to happen?

              Fortunately, I know how to undo the problem (if the import breaks NinjaTrader), but not prevent it from happening.

              The behavior seems to vary from machine to machine as well, which makes it difficult to debug.

              Thanks!

              Comment


                #8
                No,

                I did not find a solution. From memory I think I ended up renaming the enum and the problem went away... even though I could not find that enum anywhere else.

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by chazyang, Today, 08:11 AM
                1 response
                4 views
                0 likes
                Last Post NinjaTrader_PatrickG  
                Started by Erwin Beckers, 11-04-2018, 02:39 AM
                6 responses
                78 views
                2 likes
                Last Post koganam
                by koganam
                 
                Started by sergey_z, Today, 02:34 AM
                3 responses
                14 views
                0 likes
                Last Post NinjaTrader_PaulH  
                Started by frankduc, Today, 05:24 AM
                5 responses
                19 views
                0 likes
                Last Post NinjaTrader_PaulH  
                Started by shmarola, Today, 01:01 AM
                0 responses
                4 views
                0 likes
                Last Post shmarola  
                Working...
                X