Example:
Entryprice: 20
Shortstop: 25
Shortprofit: 10 . I need set this price but i dont know the correct syntax.
I try with this but dont work
// Set 1
if ((EMA1[0] < EMA2[0])
&& (CrossBelow(Close, EMA3, 1))
&& (Position.MarketPosition == MarketPosition.Flat))
{
EnterShort(Convert.ToInt32(QuantityStocks), @"sell");
Shortloss = Swing1.SwingHigh[0];
Shortprofit = ((Swing1.SwingHigh[0] - ((Position.AveragePrice)*2 ) - (Position.AveragePrice))) ;
}
// Set 2
if (Position.MarketPosition == MarketPosition.Short)
{
ExitShortStopMarket(Convert.ToInt32(QuantityStocks ), Shortloss, @"exitshortloss", @"sell");
}
// Set 3
if (Position.MarketPosition == MarketPosition.Short)
{
ExitShortMIT(Convert.ToInt32(QuantityStocks), Shortprofit, @"sellprofit", @"sell");
}
Comment