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

Enhanced Heiken Ashi indicator

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

    #31
    OK -- thanks for the update.

    I'm baffled -- if anyone has any advice for either dj22522 or me on how to proceed with understanding the problem, please speak up.

    -----

    BTW: is there any way to run two NT installations on my one computer? My thought is that I use one for development and keep the other clean for installing and testing export packages. In the current case I would like to do a clean install, but there is no way I can afford to destroy my own environment to do so.

    --EV
    Last edited by ETFVoyageur; 02-07-2011, 03:48 PM.

    Comment


      #32
      @dj22522

      I had a thought. If you extract the .cs files from the zip file and put them in your indicators directory, you could compile each by hand and you would get an error message telling just what the problem is.

      Please do that and let me know how it goes. There are only 4 files:
      • @T3.cs, @EMA.cs -- should be no problem. These are just the standard V7 files

      • RwbLibrary.cs, RwbHA.cs -- these are my files, and I would think that compiling them would give an appropriate error message.

      FWIW: I have had one other person that I know of install this package with no problem.

      --EV

      Comment


        #33
        Originally posted by ETFVoyageur View Post
        BTW: is there any way to run two NT installations on my one computer? My thought is that I use one for development and keep the other clean for installing and testing export packages. In the current case I would like to do a clean install, but there is no way I can afford to destroy my own environment to do so.

        --EV
        Nope. The way I do it, is to have a nice clean installation with NOTHING ELSE other than the operating system and Ninja Trader, on a Virtual Machine that I have on my external drive. I make a copy of the Virtual Hard Drive file. Then every time I need a clean startup environment for my Ninja Trader exports, I overwrite the VHD with the clean copy and fire up the VM. In any one session, I just:
        1. Copy .cs file
        2. Export indicator
        3. Delete indicator

        Rinse and repeat.

        I use Oracle VirtualBox, but VMWare also has free versions.

        Comment


          #34
          Thanks for the suggestion about the virtual disk. I'll have to give it a try (but not today).

          --EV

          Comment


            #35
            Originally posted by ETFVoyageur View Post
            @dj22522

            I had a thought. If you extract the .cs files from the zip file and put them in your indicators directory, you could compile each by hand and you would get an error message telling just what the problem is.

            Please do that and let me know how it goes. There are only 4 files:
            • @T3.cs, @EMA.cs -- should be no problem. These are just the standard V7 files

            • RwbLibrary.cs, RwbHA.cs -- these are my files, and I would think that compiling them would give an appropriate error message.

            FWIW: I have had one other person that I know of install this package with no problem.

            --EV
            Hi
            Did as you explained and compiling each of the 4 cs. files gives the following errors.

            RwbLibrary cs.
            Error:
            "DisplayLocation does not contain a definition for "Chart_Panel"
            Code CS0117
            Line 296
            Column 50

            "DisplayLocation does not contain a definition for "Chart_Panel"
            Code CS0117
            Line 300
            Column 41

            "DisplayLocation does not contain a definition for "Chart_Panel"
            Code CS0117
            Line 212
            Column 60

            "DisplayLocation does not contain a definition for "Chart_Panel"
            Code CS0017
            Line 296
            Column 80

            RwbHA cs.
            Error;
            "The type or namespace name "RwbIndicator"could not be found (are you missing a using directive or an assembly reference?)"
            Code CS0246
            Line 193
            Column 26

            The EMA and T3 compiled OK.

            HTH and thx for your perseverance.

            Comment


              #36
              Is this not that same problem that we already saw with the 64-bit/32-bit thingy?

              Comment


                #37
                Originally posted by koganam View Post
                Is this not that same problem that we already saw with the 64-bit/32-bit thingy?
                I do not think so -- in that case, the guy reported that NT said the archive was corrupt.

                @dj22522 Still, that is a good point. Are you trying to do the import in 32 bits or 64 bits? Not having a 64-bit system, I'm not sure how one controls that, but Mr. K is right that I supplied a different package to someone else, and he found that he had to import it as 32-bits to work.

                The errors you report do refer to things from my code, but they make no sense -- they refer to a couple of things that have not changed in ages. Just in case, though, I have attached a brand-new export that I just made. Give it a try and let us know how it goes

                --EV
                Attached Files

                Comment


                  #38
                  Originally posted by ETFVoyageur View Post
                  I do not think so -- in that case, the guy reported that NT said the archive was corrupt.

                  @dj22522 Still, that is a good point. Are you trying to do the import in 32 bits or 64 bits? Not having a 64-bit system, I'm not sure how one controls that, but Mr. K is right that I supplied a different package to someone else, and he found that he had to import it as 32-bits to work.

                  The errors you report do refer to things from my code, but they make no sense -- they refer to a couple of things that have not changed in ages. Just in case, though, I have attached a brand-new export that I just made. Give it a try and let us know how it goes
                  .
                  --EV
                  No joy I'm afraid as per zip from post#37.
                  Using the 32-bit NT7.

                  thx

                  Comment


                    #39
                    DJ - NOT to insult your intelligence nor imply that you do not know how to import .CS files, BUT did you import the files and then "compile" them?

                    1. Unzip the RwbHA zip file
                    2. Open the "docs/bin/custom/indicators (folder) and copy the rwbHA (.cs) files into the "indicator" folder
                    3. Go to tools/edit ninjascript and then select the rwbHA indicator, select open, then F5 (compile)?

                    That should do the trick...if not, let me know.

                    MM

                    Comment


                      #40
                      Disregard my input DJ...you're dealing with THE master EV ;-)
                      Mongo

                      Comment


                        #41
                        Originally posted by dj22522 View Post
                        No joy I'm afraid as per zip from post#37.
                        Using the 32-bit NT7.

                        thx
                        @majormongo -- I believe it installed fine for you -- is that right?


                        @dj22522 -- What I am having trouble comprehending is that those errors are saying that an enum is missing a member, and that the indicator's base class (RwbIndicator) cannot be found. Both of those are there in RwbLibrary, as you can easily verify. (enum at line 25, and RwbIndicator at line 705)

                        There's no way I could be using that indicator myself if such fundamental things were wrong. As I understand it, you get the same errors with the latest export -- good in a way (consistency's sake), but I do not understand what is happening.

                        Do you get the same line numbers for the errors when you build the latest (msg #37)? I ask, because the line numbers for RwbLibrary make no sense when I look at the source. What I am wondering is whether you could somehow have an out of date copy of RwbLibrary. The base class (RwbIndicator) has not always existed. That was a fairly recent addition when I did some code cleanup.

                        I just used a graphical diff tool on the version I am running ( and which I exported for you) and the version I unzipped from the export package -- they are identical, as they should be. So the export process packaged up the correct version.

                        Could there be a build order issue? Please make sure to build RwbLibary before building RwbHA and see whether that helps.

                        --EV

                        RwbLibrary cs.
                        Error:
                        "DisplayLocation does not contain a definition for "Chart_Panel"
                        Code CS0117
                        Line 296
                        Column 50

                        EV: this says the enum definition lacks "Chart_Panel", but the definition is there at RwbLibrary line 25.

                        RwbHA cs.
                        Error;
                        "The type or namespace name "RwbIndicator"could not be found (are you missing a using directive or an assembly reference?)"
                        Code CS0246
                        Line 193
                        Column 26


                        EV: This says the base class (RwbIndicator) could not be found, but see RwbLibrary line 705 where it is defined. Note there are no strange namespaces or anything -- it is in the usual standard namespace (NinjaTrader.Indicator).

                        Comment


                          #42
                          Originally posted by ETFVoyageur View Post

                          @dj22522 -- What I am having trouble comprehending is that those errors are saying that an enum is missing a member, and that the indicator's base class (RwbIndicator) cannot be found. Both of those are there in RwbLibrary, as you can easily verify. (enum at line 25, and RwbIndicator at line 705)
                          Affirmative: In RwbLibraryI have line 25:
                          public enum DisplayLocation {Chart_Panel, Indicator-Panel}

                          and at line 705:
                          public abstract class RwbIndicator : Indicator

                          Could there be a build order issue? Please make sure to build RwbLibary before building RwbHA and see whether that helps.
                          This time I have compiled the RwLibrary first and this has compiled OK.

                          Then I tried to compile the RwbHA but this does not compile.
                          It has the following errors:
                          RwbHA
                          "DisplayLocation does not contain a definition for "Chart_Panel"
                          Code CS0117
                          Line 296
                          Column 50


                          "DisplayLocation does not contain a definition for "Indicator_Panel"
                          Code CS0117
                          Line 296
                          Column 80


                          This is what is actually written in Line 296:
                          whichLocation = (Panel < 0) ? Display.Chart_Panel : DisplayLocation.Indicator_Panel;


                          "DisplayLocation does not contain a definition for "Chart_Panel"
                          Code CS0117
                          Line 300
                          Column 41


                          This is what is actually written in Line 300:
                          if (whichLocation == DisplayLocation.Chart_Panel) {


                          "DisplayLocation does not contain a definition for "Chart_Panel"
                          Code CS0117
                          Line 212
                          Column 60


                          This is what is actually written in Line 212:
                          private DisplayLocation whichLocation =DisplayLocation.Chart_Panel;

                          Do you get the same line numbers for the errors when you build the latest (msg #37)?
                          They are the same errors except for the 2nd one above which now refers to "Indicator_Panel" rather than "Chart_Panel" but the errors, when compiling are now in the RwbHA file rather than the RwbLibrary file.

                          Just so that I am clear and so that you can be sure my process is correct ?

                          Because the Import failed:
                          1. I saved the zip to Downloads Folder
                          2. I unzipped the file to the same Downloads Folder
                          3. I was then able to see the 4 cs files
                          4. I copied the RwLibrary cs file into NT Indicators Folder
                          5. I opened this via Tools/EditNinjaScript, selected the cs file and F5. It compiled.
                          6. I then did the same for RwbHA cs file, then F5 but it did not compile
                          giving me the errors listed above.
                          7. The EMA and T3 already existed in the Indicator Folder.
                          8. When unzipping the file there is also "Info.xml".
                          I have not done anything with this.
                          Should I have done ?

                          Using 32bit NT
                          Build 7.0.0.22

                          Many thx for you efforts EV
                          Last edited by dj22522; 02-08-2011, 12:40 AM. Reason: added the underlined text

                          Comment


                            #43
                            Originally posted by dj22522 View Post
                            Because the Import failed:
                            1. I saved the zip to Downloads Folder
                            2. ...
                            8. When unzipping the file there is also "Info.xml".
                            I have not done anything with this.
                            Should I have done ?

                            Using 32bit NT
                            Build 7.0.0.22

                            Many thx for you efforts EV
                            Efforts -- you are welcome. I'm anxious to see this work for you, and happy if I can help make that happen.

                            XML file -- all that is in this particular one is the NT version that exported the software. I presume to allow the NT installer to do compatibility checking, but I do not really know. In any case, nothing you need worry about when importing by hand as you are doing.

                            Your methodology -- looks good to me.

                            The RwbHA build errors -- I do not understand, because the enum is defined (RwbHA line 182), and the namespace it is in has a "using" statement (RwbHA line 177). As previously noted, it builds and runs for me and for others.

                            NT version -- I note that you are not quite up to date. Current is V 7.0.1000.2 -- since we appear to be having a build difference, how about updating your machine to the latest NT version and seeing whether the build goes any better? I do not know that will fix anything, but it will not hurt and just now the fewer differences the better.

                            --EV

                            Comment


                              #44
                              It is now looking to me as if the RwbHA file is expecting an explicit reference to the enums defined in the RwbLibrary. You may have to have an explicit using statement for the relevant namespace. Why may this be required in some instances, and not in others? Welcome to the wonderful world of Microsoft. I vaguely recollect once having to do such a thing: explicitly specify a namespace from another indicator that I referenced, before I could get things to compile, but that is a while back, and the details are hazy; it could have been something else.

                              Comment


                                #45
                                Originally posted by koganam View Post
                                It is now looking to me as if the RwbHA file is expecting an explicit reference to the enums defined in the RwbLibrary. You may have to have an explicit using statement for the relevant namespace. Why may this be required in some instances, and not in others? Welcome to the wonderful world of Microsoft. I vaguely recollect once having to do such a thing: explicitly specify a namespace from another indicator that I referenced, before I could get things to compile, but that is a while back, and the details are hazy; it could have been something else.
                                I think you are on the right track, and the problem is tied up with namespaces and the enums. As you know from other threads, the lack of reproducibility in builds bothers me. I am very interested in why it builds for me, but not for the OP. I would not expect that this one has anything to do with whatever else is installed.

                                I could believe a compiler difference, though, which is why I asked dj22522 to upgrade his system. I would still like to hear whether or not that fixes the problem.

                                The situation with the enums is:
                                • RwbHA defines its enum, in its own namespace, and has a using directive for that namespace

                                • RwbLibrary defines the same enum, with the same values, in a different namespace. RwbHA does NOT have a using statement for that namespace.

                                • Why both definitions? Historical accident -- RwbHA had its before the library got one, and since it always compiled for me I never noticed.

                                @dj22522 -- I have fixed RwbHA to just use the library version, and have attached an updated export. Please give it a try and let us know how it goes.

                                --EV
                                Attached Files

                                Comment

                                Latest Posts

                                Collapse

                                Topics Statistics Last Post
                                Started by Waxavi, Today, 02:10 AM
                                0 responses
                                3 views
                                0 likes
                                Last Post Waxavi
                                by Waxavi
                                 
                                Started by TradeForge, Today, 02:09 AM
                                0 responses
                                8 views
                                0 likes
                                Last Post TradeForge  
                                Started by Waxavi, Today, 02:00 AM
                                0 responses
                                2 views
                                0 likes
                                Last Post Waxavi
                                by Waxavi
                                 
                                Started by elirion, Today, 01:36 AM
                                0 responses
                                4 views
                                0 likes
                                Last Post elirion
                                by elirion
                                 
                                Started by gentlebenthebear, Today, 01:30 AM
                                0 responses
                                4 views
                                0 likes
                                Last Post gentlebenthebear  
                                Working...
                                X