I'm using QuotesReceived, OrderUpdates and TradeUpdates events in my .Net code. However strangely only TradeUpdateEvent is not triggered even though there are trades happening in my trading account. QuotesReceived and OrderUpdates are working fine. Here is the snapshot of the code I'm using
And then I'm using the following eent handler to process the TradeUpdateEvents. Here I'm just trying to write a message to database table. However this event handler is never called by the event. Am I missing anything here?
public void Trades_Received(object sender, KiteNet.TradeUpdateEventArgs ex2) { if (objKite.Symbol_Download_Status) { SqlConnection conn1 = new SqlConnection("Data Source=(local);Initial Catalog=Zerodha;Integrated Security=SSPI"); conn1.Open(); SqlCommand comm1 = new SqlCommand("insert into StackTrace_Zerodha values('Inside Trades Received from net code')", conn1); comm1.ExecuteNonQuery(); conn1.Close(); } }
Trade-updates are not supported by Kite API, it is just provided for compatibility with Upstox API.
Only order updates are sent by Kite API
There is no trade updates.