public async Task UpdateItems() { listItems = new List <string>(); string test = Intent.GetStringExtra("ListObject"); string trimmed = Regex.Unescape(test); Console.WriteLine(test); list = new ListsObj().DirtyParse(JToken.Parse(test)); //sample code to retrieve list object from lists.cs //list = JsonConvert.DeserializeObject<ListsObj>(Intent.GetStringExtra("ListObject")); ListItemObjs = await GetItems(); listView = FindViewById <ListView>(Resource.Id.listitemslistview); listView.Adapter = new ListListAdapter(this, ListItemObjs); //sets the selection mode for the listview to multiple choice listView.ChoiceMode = Android.Widget.ChoiceMode.Multiple; //Sets the function to be called on click to the custom function OnLocationItemClick //This Function will select and deselect location values based on the item clicked. listView.ItemClick += ListView_ItemClick; listView.ItemLongClick += ListView_ItemLongClick; }
public async void UpdateListView() { listItems = new List <string>(); //ListItemObjs = await GetItems(); //sample code to retrieve list object from lists.cs list = JsonConvert.DeserializeObject <ListsObj>(Intent.GetStringExtra("ListObject")); ListItemObjs = await GetItems(); //Find listview and set adapter listView = FindViewById <ListView>(Resource.Id.listitemslistview); listView.Adapter = new ListListAdapter(this, ListItemObjs); //sets the selection mode for the listview to multiple choice listView.ChoiceMode = Android.Widget.ChoiceMode.Multiple; //Sets the function to be called on click to the custom function OnLocationItemClick //This Function will select and deselect location values based on the item clicked. listView.ItemClick += ListView_ItemClick; }
public ListAddItem(ListsObj list) { m_list = list; }