Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy not taking trades

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

    Strategy not taking trades

    I have a strategy that paints the background panels + take a trade.
    It is painting the background correctly but not taking any trades.

    Code:
    ((High[mySwing1.SwingHighBar(0, 1, 60)] < High[mySwing1.SwingHighBar(0, 2, 60)])
    &&
    (Low[mySwing1.SwingLowBar(0, 1, 60)] > (Low[mySwing1.SwingLowBar(0, 2, 60)])))
    
    {
    EnterLong(Convert.ToInt32(DefaultQuantity), "");
    BackBrush = Brush1;
    }
    Basically taking a trade when there is a higher low swing high + a lower high swing low.

    #2
    Hello Ousher,

    You may be having an ignored order, the painting indicates that the condition was true. Please try enabling TraceOrders and then check the NinjaScript output window for warnings.



    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    47 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    22 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    33 views
    1 like
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    50 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    42 views
    0 likes
    Last Post CarlTrading  
    Working...
    X