API Support Forum
User Profile

Viewing User Profile for: DRichards310


About

Dec 05, 2011 08:31 AM

Dec 06, 2011 10:07 PM

Dec 06, 2011 10:12 PM



Post Statistics
DRichards310 has contributed to 2 posts out of 5677 total posts (0.04%) in 4735 days (0.00 posts per day).

20 most recent posts:

API Support » Multiple client_OnBarsReceived per RequestBars call Dec 06, 2011 @ 10:07 PM (Total replies: 2)

I also tried simply changing post to
public void Post(APIAction action)
{
var thread = new Thread(() => { action(); });
thread.Start();
}

just to put it on a different thread, but to no effect.

Dave Richards

API Support » Multiple client_OnBarsReceived per RequestBars call Dec 06, 2011 @ 09:59 PM (Total replies: 2)

Hi,

I seem to be experiencing a problem where I recieve multiple events for each call I make. Is this normal?

A common thing I am seeing;
RequestBars
client_OnBarsReceived
RequestBars
client_OnBarsReceived
client_OnBarsReceived
client_OnBarsReceived
client_OnBarsReceived
client_OnBarsReceived

I use my own ThreadingPolicy class, but basically all I do in Post is call action() inside the worker thread you are giving me so I cannot see how that could cause this. This is a service app and so I am unable to use you normal synchronization context that queues to the windows UI thread loop.

Dave Richards