private bool SaveSerial() { ActivationManager.Clear(); ActivationManager.License = txtLicense.Text; ActivationManager.PenDrive = txtPenDrive.Text; serialTable.Rows.Cast <DataRow>().ToList().ForEach(row => { var module = ActivationManager.Module(row.GetValue <string>(EF_Serial.Code)); module.SerialNo = row.GetValue <string>(EF_Serial.Serial); module.State = row.GetValue <ActivationState>(EF_Serial.Active); module.Enabled = row.GetValue <bool>(EF_Serial.Enable); }); return(ActivationManager.Save()); }