When I export data from our reporting module, it automatically saves it as an .xls file (user does not get an option to specify what type of excel file). The user opens this file in Excel 2010, so when it gets saved again, it has an .xlsx extension. I basically end up with 2 versions of the same file (CurrentFileName.xls and CurrentFileName.xlsx). I tried to put the following code in that would automatically convert the .xls to an .xlsx when they first open the file, but it doesn't seem to work. It prompts the user with "A file named 'CurrentFileName.xls' already exists in this location. Do you want to replace it? If they say yes, the file still shows with the .xls extension. What do I need to change to make this work correctly, or is this possible?
PS - the file name will vary from user to user, so I can't put a specific file name after:
ActiveWorkbook.SaveAs FileName:="CurrentFileName.xlsx"
Thanks for your suggestions.
Bookmarks