protected virtual string GetCSSClassForRow(RepeaterItem item) { string css = null; if (!Logic.StringEmpty(activeInactiveCol)) { bool val = Convert.ToBoolean(DataBinderEx.Eval(item.DataItem, activeInactiveCol)); css += " " + (val ? "active" : "inactive"); } return(css); }
protected virtual object GetValue(object obj, GridColumn col) { object val = DataBinderEx.Eval(obj, col.DataField); foreach (IDataFormatterPlugin plugin in plugins.Select(typeof(IDataFormatterPlugin))) { val = plugin.Format(col, val); } if (col.DataFormatString != null) { val = String.Format(PluggableFormatProvider.Instance, col.DataFormatString, val); } if (!col.AllowHtml) { val = Server.HtmlEncode(Convert.ToString(val, CultureInfo.InvariantCulture)); } return(val); }