public void GetLogs(int hour, string paramID, Action<LogN[]> callback) { Debug.Assert(callback != null); DetailsContext context = new DetailsContext(); var q = context.GetLogsQuery(hour, paramID, ServerSave.Current.ConnectionServerNames); context.Load(q, c => { Debug.WriteLine("{0:HH:mm:ss.fff}>GetLogs", DateTime.Now); if (ProcessError(c)) { callback(null); return; } callback(ToLogNs(c.Entities.ToArray())); }, null); }