• 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 U0000999, Today, 10:33 PM
      0 responses
      2 views
      0 likes
      Last Post U0000999  
      Started by Jurase, Today, 06:47 PM
      2 responses
      7 views
      0 likes
      Last Post Jurase
      by Jurase
       
      Started by GTBrooks, Today, 05:53 PM
      0 responses
      4 views
      0 likes
      Last Post GTBrooks  
      Started by jeronymite, Today, 04:50 PM
      0 responses
      7 views
      0 likes
      Last Post jeronymite  
      Started by daigo1, Today, 04:41 PM
      0 responses
      25 views
      0 likes
      Last Post daigo1
      by daigo1
       
      Working...
      X