protected void Page_Load(object sender, EventArgs e) { if (Session["sign"].ToString() == "") { Response.Redirect("~/LoginNew.aspx"); } Boolean results = empauthentication.SupAuthentication(Session["sign"].ToString()); if (results == false) { Response.Redirect("~/LoginNew.aspx"); } btn_Notification.Enabled = false; int id = (int)Session["id"]; GridView1.DataSource = StoreBusinessLogic.GetAdjustbYidSuper(id); GridView1.DataBind(); for (int i = 0; i < GridView1.Rows.Count - 1; i++) { if (GridView1.Rows[i].Cells[7].ToString() == "NULL" || GridView1.Rows[i].Cells[7].ToString() == "") { btn_Notification.Enabled = true; } break; } }