title: Powershell Copy in certain line
body: <p>I want to copy the content of my text file <code>test1.txt</code> in the line 52 of my second text file <code>test2.txt</code>.
  To copy I use the following commands:</p>
  
  <pre><code>$a=Get-Content "C:\Users\Administrator\Destop\test1.txt"
  "$a"|Out-File "C:\Users\Administrator\Desktop\test2.txt" -Append
  </code></pre>
  
  <p>But how can I define a specific line? 
  And how to overwrite when there is something?</p>