Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy callbacks

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

    Strategy callbacks

    Hi,

    Can anyone point me to the correct way to register a callback into a strategy with a custom DLL? This is for the community, I know this is not supported directly although I will take advice from wherever I can get it.

    I added the references, etc to get the DLL to compile but once I did that, NinjaTrader was decidedly not a happy camper.

    I got compile errors within NinjaTrader saying access to one of the XML files was denied (prior to comiling the DLL that was not an issue) and I got a strange error from @ADL (indicator) saying something to the effect it was referencing a reference Strategy.Strategy that did have a using statement. Of course, I couldn't add one since that is a system component.

    I am simply trying to call back into the strategy from the DLL. It would seem I could pass in "this" from the strategy and have a pointer to any public method in the strategy.

    Any/all help appreciated.

    Best Regards,
    Scott

    #2
    Hello ScottB,

    Can you please provide us with the exact compile error(s) you are receiving?
    MatthewNinjaTrader Product Management

    Comment


      #3
      Matthew,

      This was all a clever ruse on my part to trick the programming gods. I knew if I posted something on the forum and then tried to recreate the issue, it would go away.

      Who knows, when I stopped and restarted NinjaTrader (even though I had already tried this) and recompiled everything, all was OK.

      Thanks for your help, especially the part about appeasing the programming gods.

      Best Regards,
      Scott

      Comment


        #4
        ScottB,

        Glad to hear it is working now.
        MatthewNinjaTrader Product Management

        Comment


          #5
          Matthew,

          As I said, I couldn't have done it without you.

          Best Regards,
          Scott

          Comment


            #6
            Originally posted by ScottB View Post
            Matthew,

            This was all a clever ruse on my part to trick the programming gods. I knew if I posted something on the forum and then tried to recreate the issue, it would go away.

            Who knows, when I stopped and restarted NinjaTrader (even though I had already tried this) and recompiled everything, all was OK.

            Thanks for your help, especially the part about appeasing the programming gods.

            Best Regards,
            Scott
            Ah, yes. the programming gods can have a fickle sense of humor. The only ones worse are the trading gods: their sense of humor is downright cruel.

            Comment


              #7
              Well put koganam. I have heard it said that traders who offer the proper sacrifices can sell the top a few times in their careers but buy the bottom only once. I guess that means I have a few tops to sell because I did in fact buy the bottom a few years ago.

              Of course, since I am a mean reversion scalper, I sold 4 ticks later. No kidding, I bought the e-mini at 667.25 and sold at 668.25 for a cool fifty bucks.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by Geovanny Suaza, 02-11-2026, 06:32 PM
              0 responses
              670 views
              0 likes
              Last Post Geovanny Suaza  
              Started by Geovanny Suaza, 02-11-2026, 05:51 PM
              0 responses
              379 views
              1 like
              Last Post Geovanny Suaza  
              Started by Mindset, 02-09-2026, 11:44 AM
              0 responses
              111 views
              0 likes
              Last Post Mindset
              by Mindset
               
              Started by Geovanny Suaza, 02-02-2026, 12:30 PM
              0 responses
              575 views
              1 like
              Last Post Geovanny Suaza  
              Started by RFrosty, 01-28-2026, 06:49 PM
              0 responses
              582 views
              1 like
              Last Post RFrosty
              by RFrosty
               
              Working...
              X