title: Batch rename file with variable
body: <p>I try to rename a file with a variable myVar that I have set in the for loop below. The problem is that rename is not working. Can anybody tell me why?</p>
  
  <pre><code>For /F  %%A in ('"type tmpFile2.txt"') do set myVar=%%A
  ren file1.txt file2%myVar%.txt
  </code></pre>