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

Indicator Compiler Error

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

    Indicator Compiler Error

    Hello guys,

    could anyone please check the attached for the compiler error,and ,if possible, fix it?

    Thank you very much!
    Attached Files

    #2
    I tried on my windows xp 32 bit machine... could not compile.. even including :

    using System.Windows.Forms.Design;

    does not help...

    When using the autofill,

    System.Windows.Forms.Design.

    FileNameEditor does not exist.






    ----------
    [Description("Alert sound file location")]
    [DisplayName("Sound File Name")]
    [EditorAttribute(typeof(System.Windows.Forms.Design .FileNameEditor), typeof(System.Drawing.Design.UITypeEditor))]
    public string SoundFilename
    {
    get { return _soundFilename; }
    set { _soundFilename = value; }

    Comment


      #3
      Doesn't exist either in Windows7 64 bit on my machine...




      Must wait for .net geniuses to answer....
      Attached Files

      Comment


        #4
        Changing to one of those options available does produce compilable code... whether or not it runs to your satisfaction is unknown.

        Comment


          #5
          Originally posted by sledge View Post
          Changing to one of those options available does produce compilable code... whether or not it runs to your satisfaction is unknown.
          Well,let's see

          Comment


            #6
            You gotta add a reference to the System.Design.dll since FileNameEditor is referenced to that assembly
            Ref: https://msdn.microsoft.com/en-us/lib...v=vs.110).aspx

            I had to do a dirty trick by actually adding the <string>System.Design.dll</string> to my config file, since the System is in the GAC and not directly accessible through the reference selection tool in NT.

            Comment


              #7
              @Calonious,

              how would you add it?

              Comment


                #8
                I'm away from a computer right now other wise I'd give you a screen.

                Essentially, shut down NT.
                Go to (My) Documents -> NinaTrader 7
                Right click on the config.XML and open with notepad
                There's a section for references that you'll see the other references listed.
                Add in the same <string> tag from my previous post.
                Save the file

                Open NT and try compiling again

                Comment


                  #9
                  Originally posted by Calonious View Post
                  I'm away from a computer right now other wise I'd give you a screen.

                  Essentially, shut down NT.
                  Go to (My) Documents -> NinaTrader 7
                  Right click on the config.XML and open with notepad
                  There's a section for references that you'll see the other references listed.
                  Add in the same <string> tag from my previous post.
                  Save the file

                  Open NT and try compiling again
                  Still can`t get the notion where i should put it in the Config file,sorry.

                  Comment


                    #10
                    There's a section with a tag of <references> ... list of strings...</references>
                    Inside this tag there is a list of other string references
                    Place the tag that I gave -
                    <string>System.Design.dll</string>
                    Anywhere in this list. You'll see how they are listed

                    Comment


                      #11
                      Originally posted by Calonious View Post
                      There's a section with a tag of <references> ... list of strings...</references>
                      Inside this tag there is a list of other string references
                      Place the tag that I gave -
                      <string>System.Design.dll</string>
                      Anywhere in this list. You'll see how they are listed
                      Thanks,it compiled.Out of curiosity,why such a small task of adding audible alerts have to be so complex!

                      Comment


                        #12
                        Guys,where do i see those extra Alert parameters:

                        "ZigZag alert at {0}";
                        "rearm''
                        "back/fore colors"

                        ??

                        I believe it`s for the MarketAnalyzer.I`m trying to add the indicator to the MarketAnalyzer,but it hsows nothing.

                        Comment


                          #13
                          Originally posted by outsource View Post
                          Thanks,it compiled.Out of curiosity,why such a small task of adding audible alerts have to be so complex!


                          Comment


                            #14
                            Originally posted by outsource View Post
                            Thanks,it compiled.Out of curiosity,why such a small task of adding audible alerts have to be so complex!
                            Once you step out of the closed garden of the NinjaTrader Framework, you are in C# proper. If you want to play in those waters, then you should know what is required to play there.

                            What you tried to do is not complex. You applied an attribute. If you do so, you are required to be able to reach the attribute's implementation. The c# documentation tells you what references you need, in order to use the attribute. If that reference is not already available, you are required to add the reference. It is a matter of doing what is required by the C# language.

                            It will pay you much better if instead of making snarky, snide remarks, directed at NinjaTrader, when you try and fail to do things that are not within the framework, but rather in the broader c# universe, you would instead learn the language that you are using.

                            We all started somewhere, so asking questions about advanced topics that you do not understand is not a bad thing: being rude to those who try to help, and so speak at the same advanced level implied by the question, because they naturally assume that your attempting to use advanced features means you know more than you actually do, is hardly apposite.

                            Just my $0.02. Please, tone down your sarcastic bent: it is beginning to border on being offensive.
                            Last edited by koganam; 04-25-2015, 09:58 AM.

                            Comment


                              #15
                              As simple or as complex as it was,the indicator shoots audible alerts regardless of if i set it to true or false

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by trilliantrader, Today, 08:16 AM
                              2 responses
                              6 views
                              0 likes
                              Last Post trilliantrader  
                              Started by samish18, Today, 08:31 AM
                              1 response
                              1 view
                              0 likes
                              Last Post NinjaTrader_Clayton  
                              Started by Creamers, 09-08-2023, 10:26 AM
                              6 responses
                              157 views
                              0 likes
                              Last Post JonyGurt  
                              Started by funk10101, Today, 08:14 AM
                              1 response
                              2 views
                              0 likes
                              Last Post NinjaTrader_Jesse  
                              Started by bill2023, Yesterday, 08:51 AM
                              3 responses
                              22 views
                              0 likes
                              Last Post bltdavid  
                              Working...
                              X