Author |
Topic: bid/ask change notifications (7 messages, Page 1 of 1) |
||||
---|---|---|---|---|---|
Moderators: VPfau | |||||
ENissan Posts: 11 Joined: Mar 07, 2014 |
How can I get an update whenever the bid/ask changes? I only see a way to get notified when there is a new trade.
Thanks, Eric Eric Nissan |
||||
VictorV Posts: 746 Joined: May 08, 2007 |
You need to subscribe to quotes.
Victor Vins Lead Software Developer |
||||
ENissan Posts: 11 Joined: Mar 07, 2014 |
how do I do that? I only see:
oecapi.OnDealQuoteUpdated is that what I want for the ES? Thanks. Eric Nissan |
||||
ENissan Posts: 11 Joined: Mar 07, 2014 |
oh wait I see it is onPriceChanged (quotes) vs onPriceTick (trades), right?
Eric Nissan |
||||
VictorV Posts: 746 Joined: May 08, 2007 |
You can find some explanations here: http://www.openecry.com/api/api/html/4e2865e8-7ac9-457e-8d5a-6d930f3408a8.htm
Victor Vins Lead Software Developer |
||||
ENissan Posts: 11 Joined: Mar 07, 2014 |
that's the page I am looking at. it is not 100% clear to me.
the documentation has: oecapi.OnPriceTick += new OEC.API.OnPriceChangedEvent(oecapi_OnPriceTick); oecapi.OnTicksReceived += new OEC.API.OnTicksReceivedEvent(oecapi_OnTicksReceived); but there is also oecapi.OnPriceChanged. It is not clear from the docs why they are using oecapi.OnPriceTick += new OEC.API.OnPriceChangedEvent(oecapi_OnPriceTick); (mixing prices and tick events). what is the difference between OnTickReceived and OnPriceTick? why in the first example to they overload OnPriceTick with a PriceChanged Event? shouldn't that overload OnPriceChanged? Thanks. Eric Nissan |
||||
VictorV Posts: 746 Joined: May 08, 2007 |
Both OnPriceTick, OnPriceChanged relate to quotes. But unlike to OnPriceTick, OnPriceChanged can skip some price updates, if they come too often.
OnTickReceived is related to tick subscription, not to quotes. Victor Vins Lead Software Developer |
||||