title: VBA: hold the data in copied file and delete the data in initial file
body: <p>I would like do hold the data in copied file and delete the data in initial file. My code is :</p>
  <p><code> Sub logFormState() Sheets(&quot;1 - Feuille de Suivi &quot;).Range(&quot;C5&quot;) = &quot;&quot; Sheets(&quot;1 - Feuille de Suivi &quot;).Range(&quot;C6&quot;) = &quot;&quot;</code>  ....</p>
  <pre><code>Public Sub Workbook_BeforeClose(Cancel As Boolean)
  If ActiveWorkbook.Saved Then
      ActiveWorkbook.Save
  Else
      Call logFormState
  End If
  End Sub
  </code></pre>
  <p>I'm wondering if tehere is another function to do that. The functionality of ActiveWorkbook.Saved and ActiveWorkbook.Save is not clear for me.</p>
  <p>Thank you for your help !</p>