Question:
This is a piece of my strat, but I am unsure about one item, XXXX, I wouls like for an order to be placed when the condition is met (if close...) I want to enter long 1 at the price of the last bar close (close[0].....help ??) , now, in addition , if If for example the market would increase and my position would not be filled (but the order would still stand) how do I cancel the order if the current stock price is 2 ticks above my limit entry price ? . My second condition would simply just state that if the position is filled, it would close automaticly if the bars since entrey is 1.
if (Close[0] > Open[0])
{
EnterLongLimit(1, XXXXX, "contractlong1");
PrintWithTimeStamp("contractlong1");
}
// Condition set 2
if (BarsSinceEntry() >= 1)
{
ExitLong("contractexit1", "contractlong1");
}
sending me in the right direction would be appreciated.

Comment