Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Last Price and size function

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

  • NinjaTrader_JoshP
    replied
    Pobo,

    MarketData() is what you use to grab data. If you want to get last you just change that 1 parameter to 0.

    double MarketData(string instrument, int type)
    Gets the most recent price for the specified instrument and data type. 0 = last, 1 = bid, 2 = ask. You must first call the SubscribeMarketData() function prior to calling this function.

    Leave a comment:


  • pobo123
    started a topic Last Price and size function

    Last Price and size function

    Hi

    I am able to use the MarketData function and get correct prices but am unable to obtain the last price and size using the COM Interface with VB.

    gobjNinjaClient.MarketData("6E 06-09", 1) - works

    gobjNinjaClient.Last("6E 06-09", dblPrice, intSize) - does not work

    Please does anyone know what I am doing wrong?


    Thanks

    Pobo

Latest Posts

Collapse

Topics Statistics Last Post
Started by CarlTrading, 03-31-2026, 09:41 PM
1 response
114 views
1 like
Last Post NinjaTrader_ChelseaB  
Started by CarlTrading, 04-01-2026, 02:41 AM
0 responses
66 views
1 like
Last Post CarlTrading  
Started by CaptainJack, 03-31-2026, 11:44 PM
0 responses
101 views
2 likes
Last Post CaptainJack  
Started by CarlTrading, 03-30-2026, 11:51 AM
0 responses
89 views
1 like
Last Post CarlTrading  
Started by CarlTrading, 03-30-2026, 11:48 AM
0 responses
77 views
0 likes
Last Post CarlTrading  
Working...
X