• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Link style

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

    Link style

    Hello,

    I need a link like that one:



    Please post a code that will make a control like that. I assume that I have to only bind one of the standard controls style to a predefined one in NT.

    #2
    Hello PopovMP,

    Thanks for opening the thread.

    That control is a button that has a transparent background and a transparent border brush.

    You can use Inspect tool from Microsoft to identify controls used in NinjaTrader to get an idea on how you can create a similar control, or to obtain an automation ID if you wish to override some control. This tool is a general use tool for Windows and comes with Windows Software Development Kit (SDK) for Windows 8 which can be installed with Visual Studio.

    You can get the Windows SDK here: https://developer.microsoft.com/en-u...indows-8-1-sdk

    Further information on Inspect can be found here: https://msdn.microsoft.com/en-us/lib...(v=vs.85).aspx

    I have created a video demonstrating how you can find the template button control type using Inspect: https://www.screencast.com/t/AyyNpE2NyE

    You can modify the AddOn Framework example to create a similar button as follows:
    Code:
    // Find OnNews button and attach event handler
    onNewsButton = LogicalTreeHelper.FindLogicalNode(pageContent, "onNewsButton") as Button;
    onNewsButton.BorderBrush = Brushes.Transparent;
    onNewsButton.Background = Brushes.Transparent;
    The AddOn Framework sample can be found in our help documentation on AddOns here: https://ninjatrader.com/support/help...t_overview.htm

    Keep in mind that modifying NinjaTrader controls and using C# code that is outside of what we have documented escapes what we can provide support for. There may be an internal change that breaks those types of modifications.

    There is a sample written by our colleague Jessica that overrides some controls that can be referenced here: http://ninjatrader.com/support/forum...644#post490999 This is all the direction we can offer for these unsupported techniques.

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

    Comment


      #3
      Excellent replay.

      Thank you!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by yukashg, Yesterday, 09:56 PM
      1 response
      11 views
      0 likes
      Last Post NinjaTrader_ChrisSch  
      Started by cutzpr, Yesterday, 09:19 PM
      0 responses
      6 views
      0 likes
      Last Post cutzpr
      by cutzpr
       
      Started by nestorjt23, Yesterday, 08:55 PM
      3 responses
      18 views
      0 likes
      Last Post NinjaTrader_EricB  
      Started by 7robert, Yesterday, 08:30 PM
      1 response
      12 views
      0 likes
      Last Post 7robert
      by 7robert
       
      Started by mav8rick, Yesterday, 07:46 PM
      0 responses
      7 views
      0 likes
      Last Post mav8rick  
      Working...
      X