Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

OnTimer event

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

    #16
    jonnyg, did you work fully alongside the reference sample provided on this, this still compiles well for me here - the documentation will be overhauled and streamlined for NT7, sorry for the confusion.

    Believe you would see this because you don't have the Timer included thus it would need a bars object to sync to for the custom event call.
    BertrandNinjaTrader Customer Service

    Comment


      #17
      Yes, I was working with the reference sample. I think there were two primary things that messed me up. #1 was the documentation example that uses only one argument (the CustomEvent object) and #2, I was not passing in the correct barsindex value. I'm happy now with my stuff working and the promise of NT7 and updated documentation on the way.

      Comment


        #18
        The V7.0 documentation on TriggerCustomEvent() is still incorrect.

        And yes, I know there's a reference sample that is correct. But I don't always want to have to go to reference sample files instead of just looking in the help.

        By the way, has anyone at NinjaTrader ever put together an installation file that contains all reference sample files so interested user's don't have to separately download all (43) files?

        Option A:
        If the NinjaTrader person who reads this is not pro-active, you may add both of these requests to your list.

        Option B:
        Instead of adding a 5-min job to a list that will take up 5-min of evaluation over-and-over again before someone finally decides to do this, just do it now..

        Comment


          #19
          Documentation updated.

          Reference samples will not be installed by default as they are irrelevant for the majority of NT users. It does not make sense to bloat indicator/strategy lists for them with reference samples that don't do anything for them on charts. What could make sense is providing one large NS archive file to import all of the reference samples at once though. Thank you for the suggestion.
          Josh P.NinjaTrader Customer Service

          Comment


            #20
            Originally posted by NinjaTrader_Josh View Post
            Documentation updated.
            Josh,

            Thanks for getting this done. Nice to know someone's not only listening, but also getting these requests handled..

            Originally posted by NinjaTrader_Josh View Post
            What could make sense is providing one large NS archive file to import all of the reference samples at once though.
            I'll be looking forward to seeing that.

            Comment


              #21
              Originally posted by jonnyg View Post
              When I call:
              TriggerCustomEvent(MyCustomHandler, myTimer.Interval);
              as listed in the SampleCustomEvents.cs example, I get a compiler error:

              Strategy\drawtest1.cs No overload for method 'TriggerCustomEvent' takes '2' arguments CS1501 - click for info 57 4

              Also, using:
              TriggerCustomEvent(new CustomEvent(MyCustomHandler), e);
              gives the same error.

              TriggerCustomEvent(MyCustomHandler, 1, "message");
              compiles, but MyCustomHandler is never called. I know from debugging that TriggerCustomEvent *is* called.

              Can you tell me which invocation I should be trying to use? I expect I'm making an error somewhere, but am confused by the differences/conflicts in the examples and in the documentation.

              Thanks.
              Disregard trying to correlate the two into one overload. Just call your CustomEvent and pass the object afterwards. Easiest to just follow the reference sample.

              _________________
              cheat codes
              game cheat codes

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by Trader146, Today, 09:17 PM
              0 responses
              3 views
              0 likes
              Last Post Trader146  
              Started by ttrader23, 05-08-2024, 09:04 AM
              9 responses
              43 views
              0 likes
              Last Post ttrader23  
              Started by ZeroKuhl, Yesterday, 04:31 PM
              8 responses
              44 views
              0 likes
              Last Post ZeroKuhl  
              Started by reynoldsn, Today, 07:04 PM
              0 responses
              9 views
              0 likes
              Last Post reynoldsn  
              Started by puapwr, Today, 06:09 PM
              0 responses
              5 views
              0 likes
              Last Post puapwr
              by puapwr
               
              Working...
              X