Ejemplo n.º 1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromIcsehcopy(ref DataRow row, Icsehcopy entity)
 {
     row.SetField("frommsdssheetno", entity.frommsdssheetno);
     row.SetField("fromlangcd", entity.fromlangcd);
     row.SetField("tomsdssheetno", entity.tomsdssheetno);
     row.SetField("tolangcd", entity.tolangcd);
     row.SetField("rowid", entity.rowid.ToByteArray());
     row.SetField("userfield", entity.userfield);
 }
Ejemplo n.º 2
0
        public static Icsehcopy BuildIcsehcopyFromRow(DataRow row)
        {
            Icsehcopy entity = new Icsehcopy();

            entity.frommsdssheetno = row.IsNull("frommsdssheetno") ? string.Empty : row.Field <string>("frommsdssheetno");
            entity.fromlangcd      = row.IsNull("fromlangcd") ? string.Empty : row.Field <string>("fromlangcd");
            entity.tomsdssheetno   = row.IsNull("tomsdssheetno") ? string.Empty : row.Field <string>("tomsdssheetno");
            entity.tolangcd        = row.IsNull("tolangcd") ? string.Empty : row.Field <string>("tolangcd");
            entity.rowid           = row.Field <byte[]>("rowid").ToStringEncoded();
            entity.userfield       = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }