//static string replayID = "replayID" + new Random().Next().ToString("x8"); //static void EditAndContinue(string replayID = "demo1") //static void EditAndContinue() void EditAndContinue() { return; // manually restart method if modified? // some changes require full process restart. like LINQ? Console.WriteLine("enter EditAndContinue"); //var capture = new { replayID = "demo1" }; var replayID = "demo2"; //var myHistory = new Data.replayhistory().Where(x => x.replayID == replayID); //var myHistory = new Data.replayhistory().Where(x => x.replayID == replayID).Select(x => x); var service = new ApplicationWebService { }; //await service.AddHistory("headless1", 1, 1); service.AddHistory(replayID, 1, 1).Wait(); var myHistory = from x in new Data.replayhistory() where x.replayID == replayID select x; // this now works without identity select var myHistoryAll = myHistory.ToArray(); var myHistoryCount = myHistory.Count(); var distinctReplays0 = from x in new Data.replayhistory() //group x by new { x.replayID } into g //select new { g.Key.replayID, gCount = g.Count() }; group x by x.replayID into g select g.Key; var distinctReplays0All = distinctReplays0.ToArray(); var distinctReplays = from x in new Data.replayhistory() //group x by new { x.replayID } into g //select new { g.Key.replayID, gCount = g.Count() }; group x by x.replayID into g select new { replayID = g.Key // cant ask for a count can we.? //, gCount = g.Count() }; var distinctReplaysAll = distinctReplays.ToArray(); Debugger.Break(); // how many are there now? // new statement? ; // adding a new statment here causes the method to be retried var all = new Data.replayhistory().Count(); var all2 = new Data.replayhistory().Count(); var all3 = new Data.replayhistory().Count(); //var myHistory = from x in new Data.replayhistory() // where x.replayID == replayID // select x; // Z:\jsc.svn\examples\javascript\data\GoogleMapsTracker\Program.cs Debugger.Break(); // edit and continue will reset this method and step out? Console.WriteLine("exit EditAndContinue"); }
//public async Task AddHistory(string replayID, double lng, double lat) public Task AddHistory(string replayID, double lng, double lat) { Console.WriteLine(new { replayID, lng, lat }); // we have the data from the client. // lets keep it around. var key = new Data.replayhistory().Insert( new Data.replayhistoryRow { replayID = replayID, lng = lng, lat = lat } ); // look a key. useful if we want a comment attached to this row? Console.WriteLine(new { key }); // first the project needs to include xlsx // sheet1 should be named. // then rebuild project to generate the da-talayer. // slow it down. //await Task.Delay(1000 / 15); return Task.CompletedTask; // android runtime wont show the async error yet }