private void RefreshRoyalties() { //bind initial data grid to the default publisher in the DDL //System.Threading.Thread.Sleep(5000); List <Pubs._Royalty> royalties = Pubs.GetRoyalties(ddlPubs.SelectedValue); if (royalties.Count() > 0) { GridView1.DataSource = royalties; GridView1.DataBind(); } else { GridView1.EmptyDataText = "There are no sales for the selected publisher."; GridView1.DataBind(); } }
public List <Pubs._Royalty> GetRoyalties(string pubID) { return(Pubs.GetRoyalties(pubID)); }