API Support Forum
User Profile

Viewing User Profile for: TGalanos


About

Nov 25, 2014 02:06 PM

Jan 16, 2015 01:06 AM

Mar 17, 2016 09:44 AM



Post Statistics
TGalanos has contributed to 2 posts out of 5593 total posts (0.04%) in 3446 days (0.00 posts per day).

20 most recent posts:

API Support » Tick Stream data Jan 16, 2015 @ 01:06 AM (Total replies: 1)

I want to replicate behavior of Tools->Tick Stream window from OEC Trader in my own application using .NET API. I subscribe on OECClient.OnPriceTick event and log all updates using LastDateTime, LastPrice and LastVolume properties of Price object received in event argument.

My data looks very different - some ticks looks duplicated but another one looks missed. Maybe I should subscribe on other events too and implement some filtering? Could you please provide me advice how to implement 'Tick Stream' functionality in same way as it done in OEC Trader application?

Tsachi Galanos

API Support » OEC API problems in Remoting mode Dec 12, 2014 @ 07:13 AM (Total replies: 1)

During development adapter for BookMap I found two issues related to OEC API. I use Remote API mode and OEC Trader version 3.5.15.14 for development.

1. Symbol look up problem - we can look up contracts only by full name ('ESZ4' for example), not by prefix (just 'ES'). In second case OEC Trader application displays error message and no callback called so we unable to know about problem from caller side.


var api = OECClient.CreateInstance(true);
if (!api.RemoteHostingEnabled)
{
Console.WriteLine("Unable to connect OEC Remoting API.");
return;
}

api.OnSymbolLookupReceived += (lookup, contracts) =>
{
Console.Write("Symbol lookup '{0}' results: ", lookup.SearchText);
if (contracts.Count == 0)
{
Console.WriteLine("contract not found!");
}
else
{
Console.WriteLine(contracts.First.Symbol);
}
};
api.SymbolLookup("ESZ4"); // This one works fine and event fired
api.SymbolLookup("ES"); // This one cause error message and no events

Console.WriteLine("Press any key for continue...");
Console.ReadLine();


2. DoM subscription problem - any attempts to call SubscribeDOM method will lead to display same error message and we never receive DoM updates. But if contract already subscribed on DoM (it opened in DoM viewer inside OEC Trader application) all works fine. Moreother after re-login API starts to receive DoM data for all contracts referenced in UI.


var api = OECClient.CreateInstance(true);
if (!api.RemoteHostingEnabled)
{
Console.WriteLine("Unable to connect OEC Remoting API.");
return;
}

api.OnSymbolLookupReceived += (lookup, contracts) =>
{
var contract = contracts.First;
Console.WriteLine("OnSymbolLookupReceived('{0}')", contract.Symbol);

api.Subscribe(contract);
api.SubscribeDOM(contract);
};
api.OnDOMChanged += contract =>
Console.WriteLine("OnDOMChanged('{0}')", contract.Symbol);

api.SymbolLookup("ESZ4"); // Trigger error in OEC Trader application if ESZ4 not opened in DoM viewer

Application.Run(); // I need it for events receiving


How I can find real problem root cause? Is these problems are on my side or these are issues my concrete OEC Trader/API version?

Tsachi Galanos