protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.RowType == DataControlRowType.DataRow) { e.Row.Attributes.Add("onmouseover", "bg=this.style.backgroundColor;this.style.backgroundColor='#FFFFCC'"); e.Row.Attributes.Add("onmouseout", "this.style.backgroundColor=bg"); string qishu = ((HtmlInputHidden)e.Row.FindControl("HidQishu")).Value; HyperLink link = (HyperLink)e.Row.FindControl("HyperJieSuan"); System.Web.UI.HtmlControls.HtmlGenericControl div = (System.Web.UI.HtmlControls.HtmlGenericControl)e.Row.FindControl("jiesuan"); if (ReleaseBLL.IsNotProvideBonus(int.Parse(qishu)) == false) { div.InnerHtml = "<a href='javascript:openCountWin(" + qishu + ")'>" + GetTran("001154", "结算第") + qishu + GetTran("000157", "期") + "</a>"; } else { div.InnerHtml = "<a href=\"SalaryGrant.aspx\" onClick=\"return confirm('" + GetTran("000156", "第") + qishu + GetTran("001159", "期有未发放的奖金,请[撤消]后再结算...") + "');\">" + GetTran("001154", "结算第") + qishu + GetTran("000157", "期") + "</a>"; ReleaseBLL.upProvideState(int.Parse(qishu)); } } else if (e.Row.RowType == DataControlRowType.Header) { e.Row.Attributes.Add("style", "background-image:url('images/tabledp.gif')"); } }