public void UpdateBySampleID()
        {
            template_seagate_ftir_coverpage existing = _repository.Find(x => x.sample_id == this.sample_id).FirstOrDefault();

            this.ID = existing.ID;
            _repository.Edit(existing, this);
        }
 public void Update()
 {
     try
     {
         template_seagate_ftir_coverpage existing = _repository.Find(x => x.ID == this.ID).FirstOrDefault();
         _repository.Edit(existing, this);
     }
     catch (Exception ex) {
         Console.WriteLine(ex.Message);
     }
 }