Results 1 to 3 of 3

Thread: Persistent File I/O - Possible

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Feb 2000
    Location
    Dayton, OH USA
    Posts
    119

    Persistent File I/O - Possible

    I would like, if possible to attach to a log file and read newly created data from it. For instance, I have a third party application that on occasion writes to a log file. I would like to find out when the file was written to, then explicitly get the new data\line to write to a listbox. Is this possible?

    I can use the FileSystemWatcher to flag the change, but how do I explicitly pull the new data from the file and leave all the rest behind. Also, these files could be quite large, 5 meg plus in some instances.

  2. #2
    Your Ad Here! Edneeis's Avatar
    Join Date
    Feb 2000
    Location
    Moreno Valley, CA (SoCal)
    Posts
    7,339
    Why not store the file length inbetween opening, then the next time you open it you can skip x amount of bytes or space according to how long the file used to be.

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Feb 2000
    Location
    Dayton, OH USA
    Posts
    119
    Deffinitely something I had not thought of! Excellent, thanks for the feedback. I will give this a try. Any other thoughts and opinions would also be appreciated....

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width