There are special settings in this code, I use it for a text file and I assign it w/ a timestamp. All can be cut out if you don't need, I am just giving as an example.


[vba]
Dim sPath as String
Dim wb As Workbook
Dim ws?? As Worksheet
Set wb = Workbooks("yourworkbookname.xls")
Set wsEC = Worksheets("sheetname")
wb.Save
ws??.Activate
sPath = "C:\DocsandSetting\Desktop\My Documents\Excel\"

With ws??
.SaveAs Filename:=sPath & "yourworkbookname " & _
Format(Now, "m-dd-yy") & " @ " & Format(Now, "h_mm_ss am/pm") & ".txt", _
FileFormat:=xlTextMSDOS
End With
[/vba]