Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Orders not going through?

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

    Orders not going through?

    Hi,

    Using Chelsea's chartTraderButton code I have created buttons that buy and sell at the mid point between the Ask and Bid price. When I click the button the orders do not go through? Tested pre-market.

    protected void Button3Click(object sender, RoutedEventArgs e)
    {
    double midPoint = (GetCurrentAsk() + GetCurrentBid())/2;

    if ((GetCurrentAsk() - GetCurrentBid()) > 0.01 )

    EnterShortLimit(Math.Truncate(100 * midPoint) / 100);

    else

    EnterShort();
    }

    #2
    OK I found the problem. I guess strategies default to the Sim account rather than the selected account in chartTrader.

    Comment


      #3
      Hello boreland,

      It seems like you found the answer here, you will need to select the account for the strategy when applying it. If you have any further questions please feel free to update your post.


      I look forward to being of further assistance.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by NullPointStrategies, Yesterday, 05:17 AM
      0 responses
      57 views
      0 likes
      Last Post NullPointStrategies  
      Started by argusthome, 03-08-2026, 10:06 AM
      0 responses
      133 views
      0 likes
      Last Post argusthome  
      Started by NabilKhattabi, 03-06-2026, 11:18 AM
      0 responses
      73 views
      0 likes
      Last Post NabilKhattabi  
      Started by Deep42, 03-06-2026, 12:28 AM
      0 responses
      45 views
      0 likes
      Last Post Deep42
      by Deep42
       
      Started by TheRealMorford, 03-05-2026, 06:15 PM
      0 responses
      50 views
      0 likes
      Last Post TheRealMorford  
      Working...
      X