Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Indicators much start with capital letter

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

    Indicators much start with capital letter

    I copied a "CS" file into the indicators folder of NT8 under BETA5, and it didn't show in the Editor. The first letter needs to be a capital for it to show. I happen to save a sample "buttons.cs" which is what illustrated the problem. This might happen in other directories but I didn't have time to test.

    I think I remember this reported, but wanted to make sure it was stated it is still and issue with BETA5.
    Last edited by NJA_MC; 09-29-2015, 08:58 PM.

    #2
    timetest was original.

    timetest33.cs was "saved as" into the folder with textpad.
    Timetest33_upper was "saved as" into the folder with textpad.

    both showed up.
    Attached Files

    Comment


      #3
      Seems like some applications trigger the Editor to load the files. I did rename the file to a lowercase "b" and it worked fine. Here is how I can reproduce the issue:

      1) Start IE 11.0 (Complete version shown below)/Open NS editor
      2) URL: http://ninjatrader.com/support/forum...ad.php?t=74225
      3) Right click on the "Buttons.cs" file in post #55
      4) Select "save target as ..." (my filename defaults to "attachment.php")
      5) Change the destination location to /bin/custom/indicator/
      6) Save file name "buttons.cs" (seems like any fine name will do)
      7) The file does not show in the Indicators in the editor
      8) Compile, still doesn't show (If you save the file 2 times under different names you get a compile error, so it gets compiled but doesn't show in the editor)
      9) Exit editor, reload editor, file shows...

      Looks like lower case letter isn't related but the tool that saves the file.
      Attached Files

      Comment


        #4
        Works in Chrome.

        Although I DID EXIT NT8, and Restarted it after saving the file in Chrome..

        Will try IE11 now.
        Attached Files

        Comment


          #5
          ie11

          It showed up - but the code is in XML.

          buttonsie is when I thought I grabbed from #54 zip, so I did it again.

          #55 is looking like XML. LOL, it's the webpage .. I might need to try this again. Something isn't right.

          Code:
          <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
          <html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en">
          <head>
          <meta name="robots" content="noindex,follow" />
          <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
          <meta name="generator" content="vBulletin 3.8.5" />
          
          <meta name="keywords" content="Forum, automated trading, stocks, futures, forex, online trading, trading software, trading platform, ninjatrader, kinetick, market data, futures trading, stock trading" />
          <meta name="description" content="Discussion forum for the NinjaTrader trading platform" />
          The straight buttons.cs (via chrome) looks normal

          Code:
          #region Using declarations
          
          using System;
          using System.Collections.Generic;
          using System.ComponentModel;
          using System.ComponentModel.DataAnnotations;
          using System.Linq;
          using System.Text;
          using System.Threading.Tasks;
          using System.Windows;
          using System.Windows.Controls;
          using System.Windows.Input;
          using System.Windows.Media;
          using System.Xml.Serialization;
          using NinjaTrader.Cbi;
          using NinjaTrader.Gui;
          using NinjaTrader.Gui.Chart;
          using NinjaTrader.Gui.SuperDom;
          using NinjaTrader.Data;
          using NinjaTrader.NinjaScript;
          using NinjaTrader.Core.FloatingPoint;
          using NinjaTrader.NinjaScript.DrawingTools;
          
          #endregion
          
          namespace NinjaTrader.NinjaScript.Strategies
          {
          	public class Buttons : Strategy
          	{
          		#region Variables
          		
          			private Chart				 			 	ChartWindow;
          			private System.Windows.Controls.Button		Cncl  = null;		
          			private System.Windows.Controls.Button		Cls   = null;
          			private System.Windows.Controls.Button		btnONIsActive  = null;
                  private bool btnONIsActive_On = true;
          			private bool								IsToolBarButtonAdded;
          		
          			private string	atmStrategyIdB			= string.Empty;
          			private string	orderIdB				= string.Empty;
          			private string	atmStrategyIdS			= string.Empty;
          			private string	orderIdS				= string.Empty;	
          			private string vInstrument = null;
          			private int m_NumberOfLots=1;        
          	     	private bool	trade = true; 
          			private bool	auto = true; 
          			private double	realizedProfitLoss	= 0;			// Variable to hold a specific ATM strategy's profit/loss
          			private double	unrealizedProfitLoss= 0;			// Variable to hold a strategy's unrealized profit/loss
          			private double	totalPL				= 0;			// Variable to hold the running total of realized profit/loss	
          		
          		#endregion
          		
          		#region OnStateChange
          		protected override void OnStateChange()
          		{
          			if (State == State.SetDefaults)
          			{				
          				Description							= @"Buttons system";
          				Name								= "Buttons";
          				Calculate							= Calculate.OnEachTick;
          				IsOverlay							= true;
          				ScaleJustification					= NinjaTrader.Gui.Chart.ScaleJustification.Right;
          				EntriesPerDirection					= 1;
          				EntryHandling						= EntryHandling.AllEntries;
          				IsExitOnSessionCloseStrategy		= true;
          				ExitOnSessionCloseSeconds			= 60;
          				IsFillLimitOnTouch					= true;
          				MaximumBarsLookBack					= MaximumBarsLookBack.Infinite;
          				OrderFillResolution					= OrderFillResolution.Standard;
          				Slippage							= 0;
          				StartBehavior						= StartBehavior.WaitUntilFlat;
          				TimeInForce							= TimeInForce.Day;
          				TraceOrders							= false;
          				RealtimeErrorHandling				= RealtimeErrorHandling.StopCancelClose;
          				StopTargetHandling					= StopTargetHandling.PerEntryExecution;
          				BarsRequiredToTrade					= 20;
          				
          				
          			}
          			else if (State == State.Configure)
          			{
          			}
          			else if (State == State.Historical)
          			{
          				//Call Our AddToolBarButton Method - Latching Bool used to Assure this is Executed Only Once!
          				if(!IsToolBarButtonAdded) AddToolBarButton();
          			}
          			else if (State == State.Terminated)
          			{
          				//Call Our DisposeMyStuff Method - and Dispose of Anything Needing Disposed of on Termination
          				DisposeMyStuff();
          			}
          		}
          		#endregion
          Attached Files

          Comment


            #6
            I did it again in IE11, while exited from NT8.

            It downloaded the webpage again... not the .cs file. IE11 shows "attachment", type: "Firefox HTML document".

            Maybe my installation of FF is an issue in IE.

            Comment


              #7
              Originally posted by NJA_MC View Post
              Seems like some applications trigger the Editor to load the files. I did rename the file to a lowercase "b" and it worked fine. Here is how I can reproduce the issue:

              1) Start IE 11.0 (Complete version shown below)/Open NS editor
              2) URL: http://ninjatrader.com/support/forum...ad.php?t=74225
              3) Right click on the "Buttons.cs" file in post #55
              4) Select "save target as ..." (my filename defaults to "attachment.php")
              5) Change the destination location to /bin/custom/indicator/
              6) Save file name "buttons.cs" (seems like any fine name will do)
              7) The file does not show in the Indicators in the editor
              8) Compile, still doesn't show (If you save the file 2 times under different names you get a compile error, so it gets compiled but doesn't show in the editor)
              9) Exit editor, reload editor, file shows...

              Looks like lower case letter isn't related but the tool that saves the file.
              If it shows as attachment.php, you are picking up the wrong file. Try resetting IE.

              Comment


                #8
                Hello,

                Originally posted by koganam View Post
                If it shows as attachment.php, you are picking up the wrong file. Try resetting IE.
                That is correct, I have seen cases where I.E. specifically does this, generally an outdated version will not correctly save the forum attachments and instead saves attachment.php which is not a valid file.

                The solution is to not use I.E. or try updating to the most recent version and resetting as koganam said.

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

                Comment


                  #9
                  Okay,

                  Just so you know, the file is not corrupt, just the filename needs to be fixed before saving. You simple need to exit the NS Editor and Open it again before it sees the file saved by IE 11.

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by trilliantrader, 04-18-2024, 08:16 AM
                  4 responses
                  18 views
                  0 likes
                  Last Post trilliantrader  
                  Started by mgco4you, Today, 09:46 PM
                  1 response
                  7 views
                  0 likes
                  Last Post NinjaTrader_Manfred  
                  Started by wzgy0920, Today, 09:53 PM
                  0 responses
                  9 views
                  0 likes
                  Last Post wzgy0920  
                  Started by Rapine Heihei, Today, 08:19 PM
                  1 response
                  10 views
                  0 likes
                  Last Post NinjaTrader_Manfred  
                  Started by Rapine Heihei, Today, 08:25 PM
                  0 responses
                  10 views
                  0 likes
                  Last Post Rapine Heihei  
                  Working...
                  X