My research in this area has hit some dead ends so I am asking the community for some suggestions or hints to figure out my situation.
I am importing a fixed-width text file and reformatting it in Excel. When this file is imported a new workbook is created with the filename of the text file. My problem is that I am trying to figure out a way to save this workbook programmatically from another workbook without user intervention.
My attempts to save it so far have met with halfway success. I can get a file save to a specified directory with the correct filename. But it still prompts the end user to save the file when you try to close the workbook. More importantly, when opening the file that was saved Excel starts an import text file routine rather than opening the formatted text file that was created in the workbook.
The only method I have found that's somewhat close is the SaveAs method. I'm pretty sure that the reason Excel is still trying to open the saved workbook as a text file has something do to with the type of file it is when originally opened.
Can someone suggest some methods or properties to investigate or maybe offer a suggestion as to how to approach this problem? I've gone through all my Excel books and Help but can't seem to find much on the subject.
Bookmarks