public async void GetHotKeyword() { try { string results = await WebClientClass.GetResults(new Uri("http://www.bilibili.com/search?action=hotword&main_ver=v1")); HotModel model = JsonConvert.DeserializeObject <HotModel>(results); List <HotModel> ban = JsonConvert.DeserializeObject <List <HotModel> >(model.list.ToString()); list_Hot.ItemsSource = ban; } catch (Exception) { messShow.Show("读取搜索热词失败", 3000); } }
public async void GetHotKeyword() { try { string results = await WebClientClass.GetResults(new Uri("https://s.search.bilibili.com/main/hotword")); HotModel model = JsonConvert.DeserializeObject <HotModel>(results); List <HotModel> ban = JsonConvert.DeserializeObject <List <HotModel> >(model.list.ToString()); list_Hot.ItemsSource = ban; } catch (Exception) { Utils.ShowMessageToast("读取搜索热词失败", 3000); } }