public static Icsprclookupcriteria BuildIcsprclookupcriteriaFromRow(DataRow row) { Icsprclookupcriteria entity = new Icsprclookupcriteria(); entity.certcode = row.IsNull("certcode") ? string.Empty : row.Field <string>("certcode"); entity.recordcountlimit = row.IsNull("recordcountlimit") ? 0 : row.Field <int>("recordcountlimit"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }
/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromIcsprclookupcriteria(ref DataRow row, Icsprclookupcriteria entity) { row.SetField("certcode", entity.certcode); row.SetField("recordcountlimit", entity.recordcountlimit); row.SetField("userfield", entity.userfield); }