I'm on Office365, and using VBA to open a bunch of files in a directory, manipulate them, then save them in a different format (txt) and according to a naming convention.
My issue is in the saving as a filetype and following the naming convention.
I am using:
To save workbooks as text files for upload.
Our naming convention is to have a payment amount in the filename. Which is not an issue when I manually save a file, but when using this, I cannot properly save a file with a "." in it.
Example:
A filename like: Vendor - Date - Batch Total $1,108,358.46 saves as a filetype 46 instead of as .txt. Is there anyway to get past this? I'm trying to eliminate the renaming/manual naming of hundreds of files and also trying not to have to push for a new filenaming convention.
Thanks for any help you could throw my way.
My issue is in the saving as a filetype and following the naming convention.
I am using:
Code:
Dim Path As String
Path = Worksheets("FileSave").Cells(4, 3).Value
Dim filename As String
filename = Worksheets("FileSave").Cells(5, 3).Value
ActiveWorkbook.SaveAs filename:=Path & filename, FileFormat:=xlTextWindows
To save workbooks as text files for upload.
Our naming convention is to have a payment amount in the filename. Which is not an issue when I manually save a file, but when using this, I cannot properly save a file with a "." in it.
Example:
A filename like: Vendor - Date - Batch Total $1,108,358.46 saves as a filetype 46 instead of as .txt. Is there anyway to get past this? I'm trying to eliminate the renaming/manual naming of hundreds of files and also trying not to have to push for a new filenaming convention.
Thanks for any help you could throw my way.