public int?GetCounterValue(DataRow dataRow) { if (HasCounter) { ColumnField counterField = (ColumnField)View.Fields[FkCounterPrefix + Name]; string s = counterField.GetValue(dataRow); if (string.IsNullOrEmpty(s)) { return(null); } else { int value = Convert.ToInt32(s); return(value); } } else { return(null); } }
public bool EqualInDatabase(ColumnField field) { return(field.DataColumn.ColumnName.Equals(DataColumn.ColumnName)); }