title: Excel Macro to convert xlsx to xls
body: <p>i have bunch of files in folder all of them are in <code>xlsx</code> format, I need to convert them to <code>xls</code> format. This is going to be done on daily bases. </p>
  
  <p><em>I need a macro which will loop around the folder and convert the file to xls from xlsx with out changing file name.?</em></p>
  
  <p>Here is the macro I am using to loop</p>
  
  <pre><code>Sub ProcessFiles()
  Dim Filename, Pathname As String
  Dim wb As Workbook
  
  Pathname = ActiveWorkbook.Path &amp; "C:\Users\myfolder1\Desktop\myfolder\Macro\"
  Filename = Dir(Pathname &amp; "*.xls")
  Do While Filename &lt;&gt; ""
      Set wb = Workbooks.Open(Pathname &amp; Filename)
      DoWork wb
      wb.Close SaveChanges:=True
      Filename = Dir()
  Loop
  End Sub
  </code></pre>