Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
I have Excel 2000 on Win 2000 and I am trying to save the active worksheet as a tab delimited file. This is what I've tried: Dim i As Integer Dim ws As Worksheet ws = ActiveWorkbook.SaveAs("13031t.txt", xlTextWindows) But I keep getting an error on the "Saveas" saying it needs a valid function. So how do I do this? Also, what is the file format for a tab delim file? Excel VBA help does not say, it just lists the file format constants. Thanks -- Say no to fixed width tables. They look terrible in all browsers. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The Workbook SaveAs method does not return a worksheet. Try:
ActiveWorkbook.SaveAs "13031t.txt", xlTextWindows -- Jim Rech Excel MVP |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On Tue, 20 Jan 2004 11:59:16 -0500 in article <uUEKxa33DHA.360
@TK2MSFTNGP12.phx.gbl, spoke thusly... The Workbook SaveAs method does not return a worksheet. Try: ActiveWorkbook.SaveAs "13031t.txt", xlTextWindows Thanks. That worked! But I wonder why with the parentheses it didn't work and yours did. Because I had also tried: Activeworkbook.SaveAs("13031.txt", xlTextWindows) -- Say no to fixed width tables. They look terrible in all browsers. |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
But I wonder why with the parentheses
In VB when you using a returned result you use parens, else not: Dim WB as Workbook Set WB = Workbooks.Open("MyBook.xls") or Workbooks.Open "MyBook.xls" -- Jim Rech Excel MVP |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How can I save a 40meg 26,000 row file to Space Delimited format | Excel Discussion (Misc queries) | |||
Save file as semi-colon delimited? | Excel Worksheet Functions | |||
how do i save an excel file as a non-delimited, non-packed fixed | Excel Discussion (Misc queries) | |||
Unwanted Quotations Marks in Save as Tab Delimited File | Excel Discussion (Misc queries) | |||
How do I save format changes in a comma delimited file? | Excel Worksheet Functions |