title: Opening and Saving non Excel files with VBA
body: <p>I have files that when opened, are opened in Excel, but they are not Excel files themselves (they just convert when opened). I want to be able to pull some of the information in these files into another Excel sheet, but since they are not Excel files, I cant just link the files. </p>
  
  <p>I want to open these files with VBA (they will open as an Excel file) and then save them as permanent excle files so I can use them as I want. </p>
  
  <p>To open the file, I have this code: </p>
  
  <pre><code>Option Explicit
  
  Declare Function ShellExecute Lib "shell32.dll" _
  Alias "ShellExecuteA" ( _
  ByVal hWnd As Long, _
  ByVal lpOperation As String, _
  ByVal lpFile As String, _
  ByVal lpParameters As String, _
  ByVal lpDirectory As String, _
  ByVal nShowCmd As Long) As Long
  
  Function OpenAnyFile(FileToOpen As String)
  
  Call ShellExecute(0, "Open", FileToOpen &amp; vbNullString, _
  vbNullString, vbNullString, 1)
  
  End Function
  
  Sub OpenFile()
  
  Call OpenAnyFile("C:\Filename")
  
  End Sub
  </code></pre>
  
  <p>But I am unsure how to save the now opened file in this code.</p>