public async void LoadDataVtv() { this.ControlLoadding.set_Visibility(0); this._statusLoading = true; this._currentPage = this._currentPage + 1; SearchVideo searchVideo = this; ObservableCollection <Video> observableCollection = searchVideo._lsVideosLoadNewvtv; object[] text = new object[] { "http://vtv.vn/video/tim-kiem.htm?zoneVideoId=0&keywords=", this.TxtSearch.get_Text(), "&page=", this._currentPage }; ObservableCollection <Video> videoXemLai = await GetData.GetVideoXemLai(string.Concat(text)); searchVideo._lsVideosLoadNewvtv = videoXemLai; searchVideo = null; foreach (Video video in this._lsVideosLoadNewvtv) { this._lsVideosvtv.Add(video); } this.Lsvtv.set_ItemsSource(this._lsVideosvtv); this._statusLoading = false; this.ControlLoadding.set_Visibility(1); }
public async void LoadDataVtc() { this.ControlLoadding.set_Visibility(0); this.StatusLoadingvtc = true; this._currentPagevtc = this._currentPagevtc + 1; SearchVideo searchVideo = this; ObservableCollection <Video> observableCollection = searchVideo._lsVideosLoadNewvtc; object[] text = new object[] { "http://www1.tvnet.gov.vn/search.html?search_key=", this.TxtSearch.get_Text(), "&page=", this._currentPagevtc }; ObservableCollection <Video> videoVtc = await GetData.GetVideoVtc(string.Concat(text), "search"); searchVideo._lsVideosLoadNewvtc = videoVtc; searchVideo = null; foreach (Video video in this._lsVideosLoadNewvtc) { this._lsVideosvtc.Add(video); } this.LSvtc.set_ItemsSource(this._lsVideosvtc); this.StatusLoadingvtc = false; this.ControlLoadding.set_Visibility(1); }