Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

NinjaScript problem: Won't compile & I have none of my own code

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

    NinjaScript problem: Won't compile & I have none of my own code

    I've had a Ninjascript compile problem for a while... found out when a Backup complained about Script files NOT compiling... so backups are without Script files.
    I suspect problem is something to do with me trying to start a custom script, which I abandoned/deleted. I also have VisStudio installed, & had that connected to NT.

    I've just updated to the latest NT8, and one of the 3rd party imported Indicator scripts IchimokuSignal is NOT available. You can see on one screenshot, IchimokuCloud script is apparently not compiling. In the trace.txt file there are lots of complaints re the Ichimoku script. I did not write this script, found it in the NT community, but it HAS been working until the NT8 upgrade.
    I have now "excluded from compilation" the Ichimoku script.

    The other trace error comes from an "AssemblyAttributes.cs". I have no idea what its doing there. Probably unneeded.
    I am not yet a NT/C# developer. I do NOT know how to get NT scripting working again.
    Since AssemblyAttributes seems to be part of the .NET library, I need further information how to deal with it... can I just delete? However where is the source file to delete or "exclude from compilation" ?

    Any guidelines on how to get rid of these problems.

    PS: I would like to have an Ichimoku indicator. I do use it. Is there one available in the NT community?
    Attached Files

    #2
    Hello rhubear,
    It seems you're getting errors related to Indicator IchimokuSignal, try to remove the one on your system & have a new one. You can download it from below link:-
    Function: draw Ichimoku clouds and signals Update of previous version 1. fixed drawing problem: now functional with NT8.0.7.0 2. added integer series for external access: public Series iExt_Signal public Series iExt_SignalStrength The Signal and SignalStrength values are shown on the variable definition section. Also be sure to check out the Ichimoku Cloud Indicator!

    If this is not the one you were using, this solution may not work for you.

    Comment


      #3
      Hello rhubear,

      Thanks for your post.

      Another client had this issue and resolved it after installing a clean environment. You could do the same and that would resolve the issue, but I would like to see if we can find out how the compiler is finding the duplicate attribute.

      Try this first

      If you search for "System.Runtime.Versioning" or "AssemblyAttributes" in the Documents\NinjaTrader 8\bin\Custom\ folder, does anything turn up? If so, please move that file out of the bin/Custom folder and then test compiling again. If you have some detail on how those files got there, it will be helpful to note for other clients that may hit this issue.

      Try this second

      If this does not turn anything up, I may then suggest performing a Repair operation with a NinjaTrader installer after you have renamed the Documents\NinjaTrader 8\bin folder to something like "binSAVE." This will create a new bin folder that is clean with only system NinjaScripts added.

      We should not see an issue compiling here, however any 3rd party DLL's would be excluded and we will see compile errors there. You could remove the references from the NinjaScript Editor (Right Click > References) or add the DLL's and associated CS files back in for those DLL's to resolve those errors, but I would suggest testing with the references removed first as a sanity check.

      Once you see that everything compiles, you can bring in the CS files (and DLL's) from your binSAVE\Custom\folder and everything will be back in working order.

      Installers can be downloaded here - https://ninjatrader.com/PlatformDirect

      Related thread: https://ninjatrader.com/support/foru...jascript-error

      If you find the file that has the duplicate attribute added, please report back here.

      We look forward to assisting.
      JimNinjaTrader Customer Service

      Comment


        #4
        Thanks for the answer. Ichimoku indicator is not the only error. I have now disabled/excluded Ichimoku, and still get this 1 error which is the original error I was getting.

        This is what I'm stuck on.

        PS I'm fairly certain you found the same Ichimoku indicator I found.... I may try to learn enough C# to edit it, or try and find another one.

        Comment


          #5
          Hello rhubear,
          So you can try to repair but I believe it won't fix your issue. You can delete AssemblyAttributes.cs & see if it works.
          You should rename NT8 folder (Documents\NinjaTrader 8) & have a clean install then copy the backup files one by one. Avoid using the backup file (.nt8bk)

          Comment


            #6
            OK! We have all results....

            I found AssemblyAttributes in folder: C:\Users\rahee\Documents\NinjaTrader 8\bin\Custom\obj\Debug.
            Deleted it. The filename was very complicated (didn't even know it was legal filename!)...
            ".NETFramework,Version=v4.5.AssemblyAttributes .cs" .... I thought NT listed it as a description.

            Once that was deleted, I hit Compile button in editor, that ran w no errors. I then enabled Ichimoku Indicator for compile.
            Compile then successfully completed again.
            I have confirmed Ichimoku is now visible & available.
            I also started a backup job (which previously failed when inc scripts). Backup now works (I guess bc scripts now compile).

            OK, so I'm gonna be careful what I do with addons etc I guess. I will not connect Vis Studio to NT8 for the time being.
            Next time I know where to look for wierd stuff.

            Appreciate the EASY SOLUTION!!
            Last edited by rhubear; 11-13-2020, 08:33 AM.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by jeronymite, 04-12-2024, 04:26 PM
            3 responses
            44 views
            0 likes
            Last Post jeronymite  
            Started by Barry Milan, Yesterday, 10:35 PM
            7 responses
            20 views
            0 likes
            Last Post NinjaTrader_Manfred  
            Started by AttiM, 02-14-2024, 05:20 PM
            10 responses
            179 views
            0 likes
            Last Post jeronymite  
            Started by ghoul, Today, 06:02 PM
            0 responses
            10 views
            0 likes
            Last Post ghoul
            by ghoul
             
            Started by DanielSanMartin, Yesterday, 02:37 PM
            2 responses
            13 views
            0 likes
            Last Post DanielSanMartin  
            Working...
            X