LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default Append Records to a Text File

I'm writing code that creates quite a few thousand records and
ultimately saves them into a TXT file. In some scenarios, my record
count exceeds the Excel row limit of 65,536. In these cases, of
course, I need to dump some of the records out of Excel into the text
file so that I don't overflow.

I have no problem saving the first set of records into the text file.
What I am wondering is if anybody has any ideas as to how I can append
the second set of records onto the same text file. Let's say that my
procedure creates 70,000 records. My algorithm might look like this:

For x = 1 to 3500
'create 1st record set
Next
ActiveWorkbook.SaveAs Filename:=OutputFile, FileFormat:=xlText
For x = 35001 to 70000
'create 2nd record set
Next
'Append data to first .txt file - This is where I am stuck

Is there a way to write these records into the text file without
bringing it back into Excel? I tried using Word, but it was
prohibitively slow and I don't know much about VBA in Word. I could
use Access, but nobody in our office besides me has any experience in
Access and this will be a shared app, so I'm trying to keep it as
simple as I can.

Thanks,
Randy Eastland

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help for excel macro ( to append records) Sunil Somani Excel Discussion (Misc queries) 1 September 29th 09 06:05 PM
how do i append records to an excel spreadsheet mercedesb_girl Excel Discussion (Misc queries) 2 August 29th 08 05:45 PM
Append Excel Sheet from constantly updating delimited text file Ker G Setting up and Configuration of Excel 1 April 8th 08 09:33 PM
Append text file Jeff Excel Discussion (Misc queries) 6 October 8th 07 05:56 PM
use macro to append records to worksheet goingtospace Excel Programming 0 December 2nd 04 01:12 PM


All times are GMT +1. The time now is 07:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"