S
Steph
Hi everyone. I have the below chunk of code that saves a single sheet in my
workbook as a text file. Row 1 of the excel file is very long (300+
characters). When the code runs, it truncates the contents of row 1 (don't
know how many characters - I just know all of the contents are not in the
text file). BUT, when I manually copy the contents of the excel sheet, and
past them into Notebook and save as a .txt file, all the contents of row 1
are there. Any idea why this is happening, and how I can fix it? Thanks!
Dim sh As Worksheet
Set sh = Worksheets("Sheet1")
sh.Copy
ActiveWorkbook.SaveAs Filename:="c:\Testfile.txt", FileFormat:=xlText
workbook as a text file. Row 1 of the excel file is very long (300+
characters). When the code runs, it truncates the contents of row 1 (don't
know how many characters - I just know all of the contents are not in the
text file). BUT, when I manually copy the contents of the excel sheet, and
past them into Notebook and save as a .txt file, all the contents of row 1
are there. Any idea why this is happening, and how I can fix it? Thanks!
Dim sh As Worksheet
Set sh = Worksheets("Sheet1")
sh.Copy
ActiveWorkbook.SaveAs Filename:="c:\Testfile.txt", FileFormat:=xlText