async Task DoLoadDataEquip() { ModernHttpClient.NativeMessageHandler m = new ModernHttpClient.NativeMessageHandler(); Newtonsoft.Json.JsonSerializer serializer = new Newtonsoft.Json.JsonSerializer(); JsonClient client = new JsonClient(serializer); var response = await client.GetAsync <IEnumerable <EquipmentMasterDTO> >(TimeCapServices.EquipList, new Dictionary <string, string>() { { "timeKeeperPersonnelNumber", Timekeepernumbr.ToString() }, { "workDate", Workdte.ToString() } }); EquipCount.Clear(); foreach (var item in response.Value) { EquipCount.Add((string)item.EquipmentNumber.ToString()); EquipmentCount = EquipCount.Count().ToString(); } }
async Task DoLoadData() { try { ModernHttpClient.NativeMessageHandler m = new ModernHttpClient.NativeMessageHandler(); Newtonsoft.Json.JsonSerializer serializer = new Newtonsoft.Json.JsonSerializer(); JsonClient client = new JsonClient(serializer); var response = await client.GetAsync <IEnumerable <LaborListDTO> >(TimeCapServices.LaborList, new Dictionary <string, string>() { { "timeKeeperPersonnelNumber", Timekeepernumbr.ToString() }, { "workDate", Workdte.ToString() } }); Signoutcnt.Clear(); foreach (var item in response.Value) { Signoutcnt.Add((string)item.EmployeePersonnelNumber.ToString()); Signoutcount = Signoutcnt.Count().ToString(); } } catch (Exception ex) { new UIAlertView("Oops", "No Record Available", null, "OK", null).Show(); System.Console.WriteLine(ex.Message); } }