Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to decorate a parameter to open file explorer

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

    How to decorate a parameter to open file explorer

    In NinjaTrader 7, we were able to create a parameter to select a file from the file system. Something like this:


    PHP Code:
    [EditorAttribute(typeof(System.Windows.Forms.Design.FileNameEditor), typeof(System.Drawing.Design.UITypeEditor))]
    [
    Gui.Design.DisplayName("Sound File")]
    [
    Description("Sound to output.")]
    [
    Category("My Category")]
    [
    Browsable(true)]
    public 
    string MyFileName
    {
          
    get { return _FileName; }
          
    set _FileName value; }


    When I add that EditorAttribute and FileNameEditor in NT8 it seems to be ignored. Does anyone know the new technique?

    (I'm sorry if it's obvious, but I did some searches and failed to find any hits)

    Thanks in advance!

    #2
    Hi neoikon,

    Yes, it is possible to use a file picker in NinjaTrader 8.

    Code:
    [PropertyEditor("NinjaTrader.Gui.Tools.FilePathPicker", Filter="Any Files (*.*)|*.*")]
    http://ninjatrader.com/support/forum...ad.php?t=78796
    Last edited by NinjaTrader_ChelseaB; 03-28-2017, 03:39 PM.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Perfect! Thanks!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Ithinkimlost, Yesterday, 08:50 PM
      1 response
      9 views
      0 likes
      Last Post NinjaTrader_PaulH  
      Started by Stanfillirenfro, Today, 05:31 AM
      0 responses
      13 views
      0 likes
      Last Post Stanfillirenfro  
      Started by sidlercom80, Today, 04:45 AM
      0 responses
      3 views
      0 likes
      Last Post sidlercom80  
      Started by NT-Roland, Today, 04:44 AM
      0 responses
      4 views
      0 likes
      Last Post NT-Roland  
      Started by knarfoe, Today, 04:26 AM
      0 responses
      2 views
      0 likes
      Last Post knarfoe
      by knarfoe
       
      Working...
      X