Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Error on strategy doesn't apppear on log

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

    Error on strategy doesn't apppear on log

    Hello,

    I have an exit strategy that opens a fake position to close it. When executing the code it the line of the strategy appears yellow (I understand this means error) but no error line appears on the log label. None on the output window. I paste the code to see if you find anything:

    if (Position.MarketPosition == MarketPosition.Flat && PosOpened == false && Historical)
    {
    if (PositionType == "L")
    MyOpenOrder = SubmitOrder(0, OrderAction.Buy, OrderType.Market, PosQuantity, 0, 0, "", "");
    else if (PositionType == "S")
    MyOpenOrder = SubmitOrder(0, OrderAction.SellShort, OrderType.Market, PosQuantity, 0, 0, "", "");

    PosOpened = true;
    }

    Thanks

    #2
    Hello guillembm,

    Your Strategy Name cell being Yellow does not indicate and Error. This indicates that your Strategy is in a Historical Position, which I would suspect since you are checking to make sure that you are processing on Historical Data by your Historical check.

    You may see our Help Guide at the link below under the section "Understanding the Strategies tab" for more information.


    Let us know if we can be of any further assistance.
    JCNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by kempotrader, Today, 08:56 AM
    0 responses
    7 views
    0 likes
    Last Post kempotrader  
    Started by kempotrader, Today, 08:54 AM
    0 responses
    4 views
    0 likes
    Last Post kempotrader  
    Started by mmenigma, Today, 08:54 AM
    0 responses
    2 views
    0 likes
    Last Post mmenigma  
    Started by halgo_boulder, Today, 08:44 AM
    0 responses
    2 views
    0 likes
    Last Post halgo_boulder  
    Started by drewski1980, Today, 08:24 AM
    0 responses
    4 views
    0 likes
    Last Post drewski1980  
    Working...
    X