Need help in updating LTP

tasklive
I seen your example project to update LTP

Dim ltp As Dictionary(Of String, LTP) = kite.GetLTP(InstrumentId:=New String() {"NSE:INFY"})
MessageBox.Show(Utils.JsonSerialize(ltp).ToString)

I am getting a reply and displaying on messagebox as

{"NFO:BANKNIFTY20MARFUT":{"InstrumentToken":10910722,"LastPrice":29091},"NFO:NIFTY20MARFUT":{"InstrumentToken":10910978,"LastPrice":11158},"NSE:INFY":{"InstrumentToken":408065,"LastPrice":731.7}}


But, how can I display lastPrice in messagebox / textbox for each stock as get the response? Example code will be appreciated.
  • meziagroup
    Dim ltps As Dictionary(Of String, LTP) = kite.GetLTP(InstrumentId:=New String() {"NSE:INFY", "NSE:ASHOKLEY"})
    For Each item In ltps
    MsgBox(item.Key.ToString & " = " & item.Value.LastPrice.ToString)
    Next
Sign In or Register to comment.