NexusFi: Find Your Edge


Home Menu

 





Drawing Fib Levels in Stratergy


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one Futuresatm with 2 posts (0 thanks)
    2. looks_two okinawayutaka with 1 posts (0 thanks)
    3. looks_3 trendisyourfriend with 1 posts (0 thanks)
    4. looks_4 sabankaradeniz with 1 posts (0 thanks)
    1. trending_up 2,047 views
    2. thumb_up 0 thanks given
    3. group 4 followers
    1. forum 5 posts
    2. attach_file 0 attachments




 
Search this Thread

Drawing Fib Levels in Stratergy

  #1 (permalink)
 Futuresatm 
Elkridge
 
Experience: Advanced
Platform: Ninjatrader, TOS
Trading: Futures, Options
Posts: 5 since Apr 2020
Thanks Given: 2
Thanks Received: 0

Can someone please post an example of drawing fib levels using stratergy in Ninjatrader 8? Can i use these fib levels and taking a postion at 50% retracement? Appreciate your help..

Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Exit Strategy
NinjaTrader
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
ZombieSqueeze
Platforms and Indicators
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
How to apply profiles
Traders Hideout
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Just another trading journal: PA, Wyckoff & Trends
36 thanks
Spoo-nalysis ES e-mini futures S&P 500
24 thanks
Tao te Trade: way of the WLD
24 thanks
Bigger Wins or Fewer Losses?
20 thanks
GFIs1 1 DAX trade per day journal
16 thanks
  #2 (permalink)
 okinawayutaka 
Tucson
 
Experience: None
Posts: 52 since Sep 2019
Thanks Given: 1
Thanks Received: 41

look up david H at https://www.eminiaddict.com/ he has a 7 trial membership.. free.. he haS a whole system off the fibs

Reply With Quote
  #3 (permalink)
 
trendisyourfriend's Avatar
 trendisyourfriend 
Quebec Canada
Market Wizard
 
Experience: Intermediate
Platform: NinjaTrader
Broker: AMP/CQG
Trading: ES, NQ, YM
Frequency: Daily
Duration: Minutes
Posts: 4,527 since Oct 2009
Thanks Given: 4,175
Thanks Received: 6,020



Futuresatm View Post
Can someone please post an example of drawing fib levels using stratergy in Ninjatrader 8? Can i use these fib levels and taking a postion at 50% retracement? Appreciate your help..

If you mean can a strategy be made in order to automatically enter a trade at 50% retracement of a swing? then the answer is Yes it can.

For this, you'd need an indicator capable to identify a swing and that can plot a retracement target level for a pullback entry and maybe plot a target profit level based on an extention percentage calculated from the length of the swing.

Reply With Quote
  #4 (permalink)
sabankaradeniz
Turkey
 
Posts: 7 since Feb 2020
Thanks Given: 0
Thanks Received: 0

As I understand you want an example of a strategy that will work on every 50% withdrawal of fibo?

Reply With Quote
  #5 (permalink)
 Futuresatm 
Elkridge
 
Experience: Advanced
Platform: Ninjatrader, TOS
Trading: Futures, Options
Posts: 5 since Apr 2020
Thanks Given: 2
Thanks Received: 0


sabankaradeniz View Post
As I understand you want an example of a strategy that will work on every 50% withdrawal of fibo?

Trying to understand how to apply fib levels in a stratergy, If i use donchian channel to identify high and lows, looking for a sample code to draw a fib levels from high to low

Started this thread Reply With Quote
  #6 (permalink)
 darkmarine 
NEW BRUNSWICK
 
Experience: Intermediate
Platform: ninjatrader
Trading: nq
Posts: 11 since Jun 2020
Thanks Given: 2
Thanks Received: 0

look below

#region Using declarations
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.Xml.Serialization;
using System.Collections.Generic;
using System.Windows.Forms;
using NinjaTrader.Cbi;
using NinjaTrader.Data;
using NinjaTrader.Indicator;
using NinjaTrader.Gui.Chart;
using NinjaTrader.Strategy;
#endregion

///
/// Coded by traderpards at the direction here:
/// https://nexusfi.com/elite-circle/32758-want-your-ninjatrader-strategy-created-free-4.html
///
/// Hmmm... I seem to have forgotten to keep track of the update history.
///
/// 11-11-2014 - Added limit orders (and I have no idea if they'll work in live trading but they seem
/// to work with historical data.)
///
///

// This namespace holds all strategies and is required. Do not change it.
namespace NinjaTrader.Strategy
{
/// <summary>
/// This strategy detects when a certain Fibonacci level has been reached and then enters a trade. It exits a trade when the instrument either reaches a predetermined level or is stopped out.
/// </summary>
[Description("This strategy detects when a certain Fibonacci level has been reached and then enters a trade. It exits a trade when the instrument either reaches a predetermined level or is stopped out.")]
public class FibonacciTradeEntry : Strategy
{
#region Variables
private int iGapLower = 10;
private int iGapUpper = 50;
private int iQty = 1;
private TradeLevels entryTradeLevel = TradeLevels.p161_8;
private TradeLevels stopTradeLevel = TradeLevels.p261_8;
private TradeLevels profitTargetTradeLevel = TradeLevels.p50;
private int _161_bar = 0;
private bool b_161_barSet = false;
private int firstBar = 0;
private int tickSlop = 0;
private Color fibColor = Color.Black;

private bool bMoveStop = false;
private TradeLevels priceHitTradeLevel = TradeLevels.p100;
private TradeLevels moveStopTradeLevel = TradeLevels.p150;

private double dSessionOpen = 0.00;
private double dPrevSessionClose = 0.00;

private int numbBarsLastEmail = 0;
private bool bSendEmail = true;
private int startTime = 080000; // Start trading time
private int endTime = 110000; // End trading time
private int warnTime = 210000; // Warn time if in a live trade
private string emailTo = string.Empty;
private string emailFrom = string.Empty;

public enum TradeLevels { p23_6, p38_2, p50, p61_8, p76_4, p100, p150, p161_8, p261_8, zero, n23_6, n38_2, n50, n61_8, n76_4, n100, n150, n161_8, n261_8 }
public enum TradeDir { NO_TRADE, LONG, SHORT }
private TradeDir tradeDir = TradeDir.NO_TRADE;

Dictionary<string, double> levels;
Dictionary<TradeLevels, string> tradeLevelStrings;

private System.Windows.Forms.ToolStrip strip = null;
private System.Windows.Forms.ToolStripButton btnEmail = null;
private System.Windows.Forms.ToolStripSeparator sepL = null;
private System.Windows.Forms.ToolStripSeparator sepR = null;

private Font boldFont = new Font("Arial", 8,FontStyle.Bold);
private bool buttonsloaded = false;
#endregion

/// <summary>
/// This method is used to configure the strategy and is called once before any strategy method is called.
/// </summary>
protected override void Initialize()
{
CalculateOnBarClose = true;

levels = new Dictionary<string, double>();
tradeLevelStrings = new Dictionary<TradeLevels, string>();

}

#region OnStartup
protected override void OnStartUp()
{
tradeLevelStrings[TradeLevels.p23_6] = "23.6";
tradeLevelStrings[TradeLevels.p38_2] = "38.2";
tradeLevelStrings[TradeLevels.p50] = "50";
tradeLevelStrings[TradeLevels.p61_8] = "61.8";
tradeLevelStrings[TradeLevels.p76_4] = "76.4";
tradeLevelStrings[TradeLevels.p100] = "100";
tradeLevelStrings[TradeLevels.p150] = "150";
tradeLevelStrings[TradeLevels.p161_8] = "161.8";
tradeLevelStrings[TradeLevels.p261_8] = "261.8";
tradeLevelStrings[TradeLevels.zero] = "0";
tradeLevelStrings[TradeLevels.n23_6] = "-23.6";
tradeLevelStrings[TradeLevels.n38_2] = "-38.2";
tradeLevelStrings[TradeLevels.n50] = "-50";
tradeLevelStrings[TradeLevels.n61_8] = "-61.8";
tradeLevelStrings[TradeLevels.n76_4] = "-76.4";
tradeLevelStrings[TradeLevels.n100] = "-100";
tradeLevelStrings[TradeLevels.n150] = "-150";
tradeLevelStrings[TradeLevels.n161_8] = "-161.8";
tradeLevelStrings[TradeLevels.n261_8] = "-261.8";

// Add a button to the toolstrip
if( ChartControl != null )
{
System.Windows.Forms.Control[] controls = ChartControl.Controls.Find("tsrTool", false);
if( controls.Length > 0 )
{
strip = (System.Windows.Forms.ToolStrip)controls[0];

sepL = new ToolStripSeparator();
strip.Items.Add(sepL);

btnEmail = new System.Windows.Forms.ToolStripButton("btnEmail");
btnEmail.Font = boldFont ;
btnEmail.ForeColor = Color.White;
btnEmail.BackColor = Color.Green;
btnEmail.Text = "Allow email";
btnEmail.ToolTipText = "Toggle to turn sending email on/off.";

strip.Items.Add(btnEmail);
btnEmail.Click += btnEmail_Click; // Event handler to do the toggling

sepR = new ToolStripSeparator();
strip.Items.Add(sepR);

buttonsloaded = true;
}
}
}
#endregion

#region Event handlers
private void btnEmail_Click( object sender, EventArgs e )
{
if( btnEmail.Text == "Allow email" )
{
// Going to suspending trading
bSendEmail = false; // Do not send email
btnEmail.Text = "Suspend email";
btnEmail.Font = boldFont;
btnEmail.ForeColor = Color.White;
btnEmail.BackColor = Color.DarkRed;
}
else if( btnEmail.Text == "Suspend email")
{
// Going to allowing for sending of email
bSendEmail = true; // Allow sending of email
btnEmail.Text = "Allow email";
btnEmail.Font = boldFont ;
btnEmail.ForeColor = Color.White;
btnEmail.BackColor = Color.Green;
}
}
#endregion

#region OnBarUpdate
/// <summary>
/// Called on each bar update event (incoming tick)
/// Algorithm:
/// 1. Determine whether or not we have a bearish gap, a bullish gap or no gap and whether or not the gap is
/// within a user-defined range for trading. If it is:
/// 2. Buy at the 161.8 level
/// 3. Place a stop at the 261.8 level
/// 4. Place a profit target at the 60 level
///
/// Note: The user would also like some kind of ATM trailing stop option coded but I don't understand any
/// of that so until I do, this strategy will not attempt that.
/// </summary>
protected override void OnBarUpdate()
{
if( Bars.FirstBarOfSession )
{
dSessionOpen = Open[0];
dPrevSessionClose = BarsArray[0].GetDayBar(1).Close;
setFibLevels();
plotFibLevels();

firstBar = CurrentBar;
b_161_barSet = false;

// 1. Measure the gap
double gap = Math.Abs( dPrevSessionClose - dSessionOpen )/TickSize;
if( gap >= GapLower
&& gap <= GapUpper )
{
// We're eligible for a trade, but which type?
if( dPrevSessionClose < dSessionOpen ) {
tradeDir = TradeDir.SHORT;
}
else if( dPrevSessionClose > dSessionOpen ) {
tradeDir = TradeDir.LONG;
}
else {
tradeDir = TradeDir.NO_TRADE;
}
}
else {
tradeDir = TradeDir.NO_TRADE; // We won't be taking a trade at all today
}
}

if( tradeDir == TradeDir.NO_TRADE ) {
return;
}

// If we've filled the gap, then no trade
if( (tradeDir == TradeDir.LONG && Close[0] >= dPrevSessionClose)
|| (tradeDir == TradeDir.SHORT && Close[0] <= dPrevSessionClose) )
{
tradeDir = TradeDir.NO_TRADE;
return;
}

// Check the time (** see criteria below)
if( !( ToTime(Time[0]) > StartTime
&& ToTime(Time[0]) < EndTime) )
{
return;
}

// New algorithm:
// 1. If trade hits the 161, then set "open to trade"
// a. We will cancel and mark NO_TRADE if price hits 261
// 2. If price trades over 161 and trades down below 161 on a subsequent bar, then then enter a short trade
// a. Opposite for longs.

if( !b_161_barSet
&& ( (tradeDir == TradeDir.SHORT && High[0] >= levels[tradeLevelStrings[EntryTradeLevel]])
|| (tradeDir == TradeDir.LONG && Low[0] <= levels[tradeLevelStrings[EntryTradeLevel]]) ) )
{
_161_bar = CurrentBar;
b_161_barSet = true;
}
if( (tradeDir == TradeDir.SHORT && High[0] >= levels[tradeLevelStrings[StopTradeLevel]])
|| (tradeDir == TradeDir.LONG && Low[0] <= levels[tradeLevelStrings[StopTradeLevel]]) )
{
tradeDir = TradeDir.NO_TRADE;
return;
}

if( b_161_barSet == true
&& _161_bar != CurrentBar )
{
if( tradeDir == TradeDir.SHORT
&& GetCurrentAsk() <= levels[tradeLevelStrings[EntryTradeLevel]] )
{
doShort();
}
else if( tradeDir == TradeDir.LONG
&& GetCurrentBid() >= levels[tradeLevelStrings[EntryTradeLevel]] )
{
doLong();
}
}

/*********************** Old algorithm
// If tradeDir <> NO_TRADE, then we are eligible to take a trade, if we've gotten this far.
// 1. Price has to hit the 161.8 level
if( tradeDir == TradeDir.SHORT
&& GetCurrentBid() >= levels[tradeLevelStrings[EntryTradeLevel]] )
{
doShort();
}
if( tradeDir == TradeDir.LONG
&& GetCurrentAsk() <= levels[tradeLevelStrings[EntryTradeLevel]] )
{
doLong();
}
*************************/

// More to do:
// once the ENTRY ORDER is executed should be placed other conditions to keep the trade open, apart
// from the stoploss and take proffit orders:
// * if price reaches 100% (Fibonacci level, where 0%= G1 and 100%=G2) and goes back to 150%
// (Fibonacci level, where 0%= G1 and 100%=G2) then CLOSE the trade At 150% and cancel All orders.
// In other words, when the price gets to the 100% level, just move the stop to the 150 level.
if( MoveStop )
{
if( tradeDir == TradeDir.SHORT
&& Close[0] <= levels[tradeLevelStrings[PriceHitTradeLevel]] )
{
SetStopLoss( CalculationMode.Price, levels[tradeLevelStrings[MoveStopTradeLevel]] );
}
else if( tradeDir == TradeDir.LONG
&& Close[0] >= levels[tradeLevelStrings[PriceHitTradeLevel]] )
{
SetStopLoss( CalculationMode.Price, levels[tradeLevelStrings[MoveStopTradeLevel]] );
}
}

// ** if trade has not entered at 11:30am then CANCELL ORDER.
// In other words, if the time is passed the user set time, then return like we did above.

// *** if trade is entered (ongoing) and it is one hour before closing the market (for example with
// FDAX 22:00 would be 21:00) then send an email alert whit chart and text "TRADE STILL OPEN"
// Easier to just let the user enter that time...
if( Position.MarketPosition != MarketPosition.Flat
&& ToTime(Time[0]) >= LiveTradeWarnTime )
{
if( bSendEmail
&& (CurrentBar - numbBarsLastEmail) > 2)
{
string text = "There is an open trade after the warn period.";
SendMail( EmailFrom, EmailTo, "Trade warning", text );
numbBarsLastEmail = CurrentBar;
}
}

}
#endregion

#region OnExecution
/// <summary>
/// Hmmm... We need to prevent successive losses, one right after the other if the market gaps down
/// and keeps on going. This override halts the carnage.
/// </summary>
/// <param name="exe"></param>
protected override void OnExecution( IExecution exe )
{
Trade lastTrade = null;
try
{
lastTrade = Performance.AllTrades[Performance.AllTrades.Count - 1];
if( lastTrade != null
&& lastTrade.ExitExecution == exe )
{
// Any trade, whether a winner or a loser should cause the strategy to not take any more trades.
// Only one trade allowed per day.
tradeDir = TradeDir.NO_TRADE;

// Send an email
if( bSendEmail
&& (CurrentBar - numbBarsLastEmail) > 2 )
{
string text = "Trade for today has closed.";
SendMail( EmailFrom, EmailTo, "Trade exit", text );
numbBarsLastEmail = CurrentBar;
}
}
}
catch {}
}
#endregion

#region OnTermination()
/// <summary>
/// Overridden in order to remove the toolbar stuff so the controls don't repaint on refresh
/// </summary>
protected override void OnTermination()
{
if( buttonsloaded == true )
{
strip.Items.Remove(btnEmail);
strip.Items.Remove(sepL);
strip.Items.Remove(sepR);
buttonsloaded = false;
}
}
#endregion

public override string ToString()
{
string retVal = "FibonacciTradeEntry( GapLower = " + GapLower.ToString();
retVal += ", GapUpper = " + GapUpper.ToString();
retVal += ", Entry level = " + EntryTradeLevel.ToString();
retVal += ", Profit target = " + ProfitTradeLevel.ToString();
retVal += ", Stop level = " + StopTradeLevel.ToString();
retVal += ")";
return retVal;
}

#region Utility
private void setFibLevels()
{
levels.Clear();

// If close > open, then these levels are all negative, otherwise they're positive
double reference = dPrevSessionClose - dSessionOpen;
levels.Add( "23.6", dPrevSessionClose - reference * 23.6/100 );
levels.Add( "38.2", dPrevSessionClose - reference * 38.2/100 );
levels.Add( "50", dPrevSessionClose - reference * 50/100 );
levels.Add( "61.8", dPrevSessionClose - reference * 61.8/100 );
levels.Add( "76.4", dPrevSessionClose - reference * 76.4/100 );
levels.Add( "100", dPrevSessionClose - reference * 100/100 );
levels.Add( "150", dPrevSessionClose - reference * 150/100 );
levels.Add( "161.8", dPrevSessionClose - reference * 161.8/100 );
levels.Add( "261.8", dPrevSessionClose - reference * 261.8/100 );
levels.Add( "0", dPrevSessionClose );
levels.Add( "-23.6", dPrevSessionClose + reference * 23.6/100 );
levels.Add( "-38.2", dPrevSessionClose + reference * 38.6/100 );
levels.Add( "-50", dPrevSessionClose + reference * 50/100 );
levels.Add( "-61.8", dPrevSessionClose + reference * 61.8/100 );
levels.Add( "-76.4", dPrevSessionClose + reference * 76.4/100 );
levels.Add( "-100", dPrevSessionClose + reference * 100/100 );
levels.Add( "-161.8", dPrevSessionClose + reference * 161.8/100 );
levels.Add( "-261.8", dPrevSessionClose + reference * 261.8/100 );
}

/// <summary>
/// We just want to draw a tiny line with a label on the chart so the user can know when to expect
/// a trade to occur.
/// </summary>
private void plotFibLevels()
{
int i = 0;
foreach (KeyValuePair<string, double> pair in levels)
{
DrawLine(pair.Key+CurrentBar, 3, pair.Value, 1, pair.Value, FibLevelColor );
DrawText( "txt"+(i++)+CurrentBar, pair.Key, 5, pair.Value, FibLevelColor );
}
}
#endregion

#region Trade helpers
private void doShort()
{
// EnterShort( Qty, "Short(" + Qty.ToString() + ")" );
EnterShortLimit( Qty, levels[tradeLevelStrings[EntryTradeLevel]]-TickSlop*TickSize, "Short(" + Qty.ToString() + ")");
SetStopLoss( CalculationMode.Price, levels[tradeLevelStrings[StopTradeLevel]] );
SetProfitTarget( CalculationMode.Price, levels[tradeLevelStrings[ProfitTradeLevel]] );

if( bSendEmail
&& (CurrentBar - numbBarsLastEmail) > 2 )
{
// Send an email
string text = "Trade has been initialized.";
SendMail( EmailFrom, EmailTo, "Trade entry", text );
numbBarsLastEmail = CurrentBar;
}
}
private void doLong()
{
// EnterLong( Qty, "Long(" + Qty.ToString() + ")" );
EnterLongLimit( Qty, levels[tradeLevelStrings[EntryTradeLevel]]+TickSlop*TickSize, "Long(" + Qty.ToString() + ")");
SetStopLoss( CalculationMode.Price, levels[tradeLevelStrings[StopTradeLevel]] );
SetProfitTarget( CalculationMode.Price, levels[tradeLevelStrings[ProfitTradeLevel]] );

if( bSendEmail
&& (CurrentBar - numbBarsLastEmail) > 2 )
{
// Send an email
string text = "Trade has been initialized.";
SendMail( EmailFrom, EmailTo, "Trade entry", text );
numbBarsLastEmail = CurrentBar;
}
}
#endregion

#region Properties
[Description("Lower boundary (in ticks) for the gap range to determine whether we will consider a trade")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("\t\t\t\t\t\t\t\tGap - lower bound")]
public int GapLower
{
get { return iGapLower; }
set { iGapLower = Math.Max(1, value); }
}
[Description("Upper boundary (in ticks) for the gap range to determine whether we will consider a trade")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("\t\t\t\t\t\t\tGap - upper bound")]
public int GapUpper
{
get { return iGapUpper; }
set { iGapUpper = Math.Max(1, value); }
}
[Description("Number of contracts to trade")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("\t\t\t\t\t\tQuantity")]
public int Qty
{
get { return iQty; }
set { iQty = Math.Max(1, value); }
}
[Description("The Fibonacci level at which to enter")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("\t\t\t\t\tEnter trade level")]
public TradeLevels EntryTradeLevel
{
get { return entryTradeLevel; }
set { entryTradeLevel = value; }
}
[Description("The Fibonacci level at which to place a stop loss")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("\t\t\t\tStop loss trade level")]
public TradeLevels StopTradeLevel
{
get { return stopTradeLevel; }
set { stopTradeLevel = value; }
}
[Description("The Fibonacci level at which to place a profit target")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("\t\t\tProfit target trade level")]
public TradeLevels ProfitTradeLevel
{
get { return profitTargetTradeLevel; }
set { profitTargetTradeLevel = value; }
}
[Description("True to move stop if certain level is hit.")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("\t\tMove stop")]
public bool MoveStop
{
get { return bMoveStop; }
set { bMoveStop = value; }
}
[Description("If \"Move stop\" is true, the Fibonacci level that price needs to reach before we move the stop loss to a different level.")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("\tPrice hit trade level")]
public TradeLevels PriceHitTradeLevel
{
get { return priceHitTradeLevel; }
set { priceHitTradeLevel = value; }
}
[Description("If \"Move stop\" is true, the Fibonacci level to which move the stop loss after a certain level is hit")]
[GridCategory("Parameters")]
[Gui.Design.DisplayNameAttribute("'Move stop to' trade level")]
public TradeLevels MoveStopTradeLevel
{
get { return moveStopTradeLevel; }
set { moveStopTradeLevel = value; }
}
[Description("Fib level color as it appears on the session open axis")]
[GridCategory("Parameters")]
[Gui.Design.DisplayName("Fib level color")]
public Color FibLevelColor
{
get { return fibColor; }
set { fibColor = value; }
}
[Description("The amount of \"slop\" to allow for a limit order to be placed a tick or two below the actual target entry.")]
[GridCategory("Parameters")]
[Gui.Design.DisplayName("Tick slop")]
public int TickSlop
{
get { return tickSlop; }
set { tickSlop = value; }
}
// Serialize Color object
[Browsable(false)]
public string FibColorSerialize
{
get { return NinjaTrader.Gui.Design.SerializableColor.ToString(fibColor); }
set { fibColor = NinjaTrader.Gui.Design.SerializableColor.FromString(value); }
}


#region Time settings
[Description("Start trading time. Format is HHMMSS and is on a 24 hour scale so 2:30 PM should be entered as 143000")]
[GridCategory("Time settings")]
[Gui.Design.DisplayName("\tTime1: Strategy begin time")]
public int StartTime
{
get { return startTime; }
set { startTime = Math.Max(000000, value); }
}
[Description("End trading time. Format is HHMMSS and is on a 24 hour scale so 2:30 PM should be entered as 143000")]
[GridCategory("Time settings")]
[Gui.Design.DisplayName("Time2: Strategy end time")]
public int EndTime
{
get { return endTime; }
set { endTime = Math.Max(000000, value); }
}
[Description("If we're still in a trade after this time, send an email warning. Format is HHMMSS and is on a 24 hour scale so 2:30 PM should be entered as 143000")]
[GridCategory("Time settings")]
[Gui.Design.DisplayName("Time3: Warn of live trade when:")]
public int LiveTradeWarnTime
{
get { return warnTime; }
set { warnTime = Math.Max(000000, value); }
}
#endregion TradeLevels

[Description("Email \"From\" address")]
[GridCategory("Email info")]
[Gui.Design.DisplayName("Email from")]
public string EmailFrom
{
get { return emailFrom; }
set { emailTo = value; }
}
[Description("Email \"To\" address")]
[GridCategory("Email info")]
[Gui.Design.DisplayName("Email to")]
public string EmailTo
{
get { return emailTo; }
set { emailTo = value; }
}


#endregion
}
}

Reply With Quote




Last Updated on August 16, 2020


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts