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

Manage Hotkeys in NinjaScript?

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

    Manage Hotkeys in NinjaScript?

    I would like to be able to do the following for hotkeys in a NinjaScript AddOn:
    • Find all hotkeys and what they are assigned to and their hotkey category
    • Assign/deassign a hotkey
    • Create/populate/destroy a new (non-system) category of hotkeys
    • Assign/deassign hotkeys for existing AddOns
    Are there any examples of these capabilities available in NinjaScript?

    Thanks!
    Multi-Dimensional Managed Trading
    jeronymite
    NinjaTrader Ecosystem Vendor - Mizpah Software

    #2
    Hello jeronymite,

    Currently there is no way to manage the existing hotkeys, there is a feature request for this which I have added your vote for SFT-2669.

    If you wanted to add key controls to something you are doing you can use the PreviewKey events (WPF concept) from the target control for that purpose. You can search the forum for PreviewKeyDown or PreviewKeyUp for some examples, this is also something you can just search for online in contrast to WPF to better understand how to use keyboard events.

    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment


      #3
      Thanks, Jesse. Whilst I am looking for the NinjaScript functionality (thanks for adding my vote to the feature request), it is also desirable to have the ability to assign/deassign hotkeys to existing AddOns in the NT UI. Thanks again!
      Multi-Dimensional Managed Trading
      jeronymite
      NinjaTrader Ecosystem Vendor - Mizpah Software

      Comment


        #4
        How do I vote for SFT-2669? I want to vote, too.

        Comment


          #5
          Hello leontancfa,

          I have added a vote.

          Please let me know if I may be of further assistance.
          JesseNinjaTrader Customer Service

          Comment


            #6
            Hello,

            I'd like to vote for this option as well please.

            Comment


              #7
              Hello KINGKODA,

              I have added a vote.

              As a side note, any further votes past this point I will add them however I will not keep adding a new post saying that I have added a vote. Please know that I have added it.

              Please let me know if I may be of further assistance.
              JesseNinjaTrader Customer Service

              Comment


                #8
                I'd also like to vote for this please.

                Comment


                  #9
                  Originally posted by jeronymite View Post
                  I would like to be able to Find all hotkeys and what they are assigned to and their hotkey category. Thanks!
                  Recently added several hotkeys to several projects and needed a way to check for conflicts..
                  Code below will print a list of all available hotkeys (assigned or not) to output window (1)
                  Code:
                  foreach(var v in NinjaTrader.Gui.HotKeys.HotKeysManager.AllHotKeys)
                  {
                       Print("-----------------------------"); 
                       Print(v.GetType().ToString()); 
                       Print("-----------------------------"); 
                       var vSplit = v.ToString().Split(new [] { ' ' });
                       foreach(string s in vSplit) Print(s);
                  }
                  Print("-----------------------------");

                  -=Edge=-
                  NinjaTrader Ecosystem Vendor - High Tech Trading Analysis

                  Comment


                    #10
                    I would like to add my vote to SFT-2669.

                    Comment

                    Latest Posts

                    Collapse

                    Topics Statistics Last Post
                    Started by andrewtrades, Today, 04:57 PM
                    1 response
                    10 views
                    0 likes
                    Last Post NinjaTrader_Manfred  
                    Started by chbruno, Today, 04:10 PM
                    0 responses
                    6 views
                    0 likes
                    Last Post chbruno
                    by chbruno
                     
                    Started by josh18955, 03-25-2023, 11:16 AM
                    6 responses
                    436 views
                    0 likes
                    Last Post Delerium  
                    Started by FAQtrader, Today, 03:35 PM
                    0 responses
                    9 views
                    0 likes
                    Last Post FAQtrader  
                    Started by rocketman7, Today, 09:41 AM
                    5 responses
                    20 views
                    0 likes
                    Last Post NinjaTrader_Jesse  
                    Working...
                    X