public override void ViewDidLoad() { base.ViewDidLoad(); var current = Connectivity.NetworkAccess; if (current == NetworkAccess.Internet) { var resultProducts = AppRuntime.MarketData.getProductsByCategories(CategoryID); if (resultProducts.ServiceResponseStatus.IsSuccess) { var listProducts = resultProducts.Products.ToList(); ProductsTableViewSource TableSource = new ProductsTableViewSource(listProducts, this); ProductsTableView.Source = TableSource; ProductsTableView.RowHeight = 176f; ProductsTableView.ReloadData(); TableSource.ProductButtonTapped -= ButtonInCellClicked; TableSource.ProductButtonTapped += ButtonInCellClicked; } else { //wait DisplayAlert("Alert", "You have been alerted", "OK"); } } }
void BindProducts() { ProductsTableView.ReloadData(); }