Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Input numeric to strategy without chart taking the key input??

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

    Input numeric to strategy without chart taking the key input??

    I have a strategy in NT8 which includes a side panel where numbers can be input. On NinjaTrader 7 this worked fine but in NT8 every time I hit a numeric I get a popup which assumes I am trying to enter a new symbol with the title "Press Esc to cancel".

    Is there a way to prevent NT8 from 'seeing this key input or at least a way to allow the input to be directed to the input box on my strategy, which to be fair DOES have focus at the time.

    Thanks,

    #2
    Hello scalp,

    You can find a sample of handing key events in the following post. https://ninjatrader.com/support/foru...PreviewKeyDown

    In NT8 you would need to know what keys you need to handle to mark each keypress you want as handled to avoid the charts existing keyboard commands.

    You can also use items like focus in your logic to avoid blocking all chart keyboard commands when you are not intending to type into your entry box.

    I look forward to being of further assistance.

    Comment


      #3
      Many thanks Jesse, I will look into that thread.

      Comment


        #4
        Originally posted by NinjaTrader_Jesse View Post
        Hello scalp,

        You can find a sample of handing key events in the following post. https://ninjatrader.com/support/foru...PreviewKeyDown

        In NT8 you would need to know what keys you need to handle to mark each keypress you want as handled to avoid the charts existing keyboard commands.

        You can also use items like focus in your logic to avoid blocking all chart keyboard commands when you are not intending to type into your entry box.

        I look forward to being of further assistance.
        Jesse

        My developer has managed to successfully implement code to intercept keystrokes with the exception of the UP and DOWN keys (up/down arrows). Do you know whether this is possible? He has indicated he cannot find a way to intercept these specific keys.

        Many thanks,


        Comment


          #5
          If anyone else has input on intercepting the UP/DOWN keys I would appreciate it.

          Thanks,

          Comment


            #6
            Hello scalp,

            I reviewed this however I don't see a specific way to catch the arrow keys in the chart window. They are not passed in the preview key event or any of the other key events I had tried.

            I look forward to being of further assistance.


            Comment


              #7
              Originally posted by NinjaTrader_Jesse View Post
              Hello scalp,

              I reviewed this however I don't see a specific way to catch the arrow keys in the chart window. They are not passed in the preview key event or any of the other key events I had tried.

              I look forward to being of further assistance.

              Jesse

              I appreciate your taking the time to check into it, many thanks.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by NullPointStrategies, Today, 05:17 AM
              0 responses
              50 views
              0 likes
              Last Post NullPointStrategies  
              Started by argusthome, 03-08-2026, 10:06 AM
              0 responses
              126 views
              0 likes
              Last Post argusthome  
              Started by NabilKhattabi, 03-06-2026, 11:18 AM
              0 responses
              69 views
              0 likes
              Last Post NabilKhattabi  
              Started by Deep42, 03-06-2026, 12:28 AM
              0 responses
              42 views
              0 likes
              Last Post Deep42
              by Deep42
               
              Started by TheRealMorford, 03-05-2026, 06:15 PM
              0 responses
              46 views
              0 likes
              Last Post TheRealMorford  
              Working...
              X