public static Saeafldsdate BuildSaeafldsdateFromRow(DataRow row) { Saeafldsdate entity = new Saeafldsdate(); entity.slctdateary = row.IsNull("slctdateary") ? 0 : row.Field <int>("slctdateary"); entity.fieldname = row.IsNull("fieldname") ? string.Empty : row.Field <string>("fieldname"); 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 UpdateRowFromSaeafldsdate(ref DataRow row, Saeafldsdate entity) { row.SetField("slctdateary", entity.slctdateary); row.SetField("fieldname", entity.fieldname); row.SetField("userfield", entity.userfield); }