View Single Post
Join Date: Dec 2004
Posts: 2,413
Reputation: Comatose is a jewel in the rough Comatose is a jewel in the rough Comatose is a jewel in the rough Comatose is a jewel in the rough 
Solved Threads: 211
Team Colleague
Comatose's Avatar
Comatose Comatose is offline Offline
Taboo Programmer

Re: Export Data to Notepad

 
0
  #7
Jan 4th, 2009
This Site will help you out a great deal. The best way to do this is something like:
  1. Dim oFile as System.IO.File
  2. Dim oWrite as System.IO.StreamWriter
  3. oWrite = oFile.CreateText(“C:\sample.txt)
  4. oWrite.WriteLine({0,10}{1,10}{2,25}”, “Date”, “Time”, “Price”)
  5. oWrite.WriteLine({0,10:dd MMMM}{0,10:hh:mm tt}{1,25:C}”, Now(), 13455.33)
  6. oWrite.Close()
Here, if you mess with the numbers that are inside the {}, you can adjust exactly where in the text file you want the data to go....If this solution doesn't work (but it should) we can try one more (ugly) way.
Reply With Quote