protected void cgvMetric_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.RowType == DataControlRowType.DataRow) { int CellIndex = 5; switch (Mode) { case enMode.List: CellIndex = 5; break; case enMode.PIAdd: case enMode.PIEdit: case enMode.PiRef: CellIndex = 4; break; } if (e.Row.DataItem is MetricTrac.Bll.Metric.Extend) { MetricTrac.Bll.Metric.Extend rData = (MetricTrac.Bll.Metric.Extend)e.Row.DataItem; if (rData.MetricTypeID == 2) { e.Row.Cells[CellIndex].Text = "---"; } } else { MetricTrac.Bll.Sp_SelectUnassignedMetricResult rData = (MetricTrac.Bll.Sp_SelectUnassignedMetricResult)e.Row.DataItem; if (rData.MetricTypeID == 2) { e.Row.Cells[CellIndex].Text = "---"; } } } }
protected void cgvMetric_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.RowType == DataControlRowType.DataRow) { int CellIndex = 6; switch (Mode) { case enMode.List: CellIndex = 6; break; case enMode.PIAdd: case enMode.PIEdit: case enMode.PiRef: CellIndex = 5; break; } if (e.Row.DataItem is MetricTrac.Bll.Metric.Extend) { MetricTrac.Bll.Metric.Extend rData = (MetricTrac.Bll.Metric.Extend)e.Row.DataItem; if (rData.AssignedOrgLocations != null) { if (rData.AssignedOrgLocations.Count > 1) { CreateToolTip(rData.AssignedLocationName, rData.AssignedLocationsNames, /*e.Row.ClientID*/ e.Row.Cells[4].ClientID); } } if (rData.MetricTypeID == 2) { e.Row.Cells[CellIndex].Text = "---"; } } else { MetricTrac.Bll.Sp_SelectUnassignedMetricResult rData = (MetricTrac.Bll.Sp_SelectUnassignedMetricResult)e.Row.DataItem; //CreateToolTip("", "", e.Row.ClientID); if (rData.MetricTypeID == 2) { e.Row.Cells[CellIndex].Text = "---"; } } } }