void Bind() { bool judge = User.IsInRole("Judge"); List <Message> list = new List <Message>(); foreach (Message m in Message.GetMessages(selmess.Filter)) { if (judge || (!judge && m.UserID == User.Identity.Name)) { list.Add(m); } } questionsGV.DataSource = list; questionsGV.DataBind(); HtmlFunctions.BeautifyGridView(questionsGV); }
protected void statusGV_DataBound(object sender, EventArgs e) { HtmlFunctions.BeautifyGridView(statusGV); }