|
-
September 7th, 2001, 01:23 PM
#1
Creating/Maintaining log files
I recently posted with questions regarding program execution and FTP transfers. All that is working perfectly, but now I have another dilema.
I'm trying to create simple log files in the VB program to track activity with the FTP. The files are simple ASCII text files, using sequential file access methods to write the data. As an option on this program I would like the administrator to have the ability to set a maximum file size and whether the log file should be overwritten or deleted when the maximum is reached. All the code is working in regard to writing the file, setting the maximum and deleting if the maximum is reached, but I'm not sure how to control overwriting the log.
The log appends itself to the bottom of the document. I would like to be able to delete the top entry(which is always the same number of lines) and then append to the bottom. This would keep the log file at the same file size each time it is written to.
I'm just not sure how exactly to do this. Suggestions? Comments?
Thanks in advance.
------------------
When the going gets tough, the tough give up.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|
Bookmarks