JohnTravolski
New Member
- Joined
- Nov 25, 2015
- Messages
- 46
- Office Version
- 2019
- Platform
- Windows
What I'm trying to achieve should be simple, but Excel keeps making it very difficult for me. All I want is a macro that does exactly the following and nothing else:
Please do not recommend anything involving "save as." I've messed around with that before and if you try and save as a tab delimited file, some entries with commas have quotes magically put around them by excel. What we need to do is simply create a text file and write the contents of all cells containing data in the active worksheet as-is into that file with the mentioned delimiters. That's it.
I've found a million examples online and none of them can seem to get past the whole quote problem. Please, please help me.
- Export all of the data in the active sheet to a text file in the active workbook directory
- The filename should be the name of the active sheet + ".txt"
- Columns should be separated by tab characters
- Rows should be separated by newline characters
- Regardless of what characters are entered in any given cell (including commas, quotes, punctuation, etc.), Excel should NOT BE PUTTING QUOTES OR ANY OTHER CHARACTERS around any of the exported data in the output file.
Please do not recommend anything involving "save as." I've messed around with that before and if you try and save as a tab delimited file, some entries with commas have quotes magically put around them by excel. What we need to do is simply create a text file and write the contents of all cells containing data in the active worksheet as-is into that file with the mentioned delimiters. That's it.
I've found a million examples online and none of them can seem to get past the whole quote problem. Please, please help me.