Macros

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Trying to prompt using a InputBox() for different files. Problem is, the
files are named the same but under different folders. (The folders are each a
different year, and the files are of the same idea with different data) I
want to be able to ask for two samely named files under two different
folders.

Any ideas?

Thanks!
 
There is a specific method for getting filenames (and their paths):

fileToOpen = Application.GetOpenFilename("Excel Files (*.xls), *.xls")
If fileToOpen <> False Then
Workbooks.Open fileToOpen
End If

Be sure to keep the If statement as it checks to see if the user
cancelled the box.
 
There is a specific method for getting filenames (and their paths):

fileToOpen = Application.GetOpenFilename("Excel Files (*.xls), *.xls")
If fileToOpen <> False Then
Workbooks.Open fileToOpen
End If

Be sure to keep the If statement as it checks to see if the user
cancelled the box.
 
You can ask by using two application.getopenfilename() commands. But remember,
only one workbook with that name can be open at any given time.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top