View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
guy guy is offline
external usenet poster
 
Posts: 2
Default Writing a CSV file

This is a fairly easy task but I'm struggling to find the right objects to
use.

I have a named range on a spreadsheet or around 20 columns and 10 rows and I
want to write that range out to a CSV file in a specific directory with a
specific name (I want the extension to end in .txt and not .csv).

So I'm thinking that I could loop over each row and inside that loop I would
loop over each column and then write the conents of each cell to the file
and put a "," between each value.

I'm not familiar with Excel VBA syntax so any pointers would be much
appreciated.

Thanks.