protected void RankDropDown_SelectedIndexChanged(object sender, EventArgs e) { WSRank rank = new WSRank(); rank.ID = int.Parse(RankDropDown.SelectedValue); LeaderboardGrid.DataSource = proxy.GetAllUsersInRank(rank); LeaderboardGrid.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { proxy = (TakiWebService)Session["Proxy"]; WSRank[] ranks = proxy.GetAllRanks(); if (!IsPostBack) { LeaderboardGrid.DataSource = proxy.GetAllUsersInRank(ranks[0]); LeaderboardGrid.DataBind(); RankDropDown.DataSource = proxy.GetAllRanks(); RankDropDown.DataBind(); } }