Results 1 to 3 of 3

Thread: textfile append

  1. #1

    Thread Starter
    Member
    Join Date
    Nov 2002
    Location
    Austria
    Posts
    52

    textfile append

    hi all!

    i want to write a headerline to an existing textfile. how can i write data in the first line?

    i only can append on the end of the textfile... not at the first position.

    thanks

  2. #2
    Hyperactive Member RealNickyDude's Avatar
    Join Date
    Nov 2002
    Location
    Watching you through the hidden camera :o
    Posts
    435
    How about:

    1/. Place the heading in variable1

    2/. Read the textfile into variable2

    3/. variable3 = variable1 & variable2

    4/. save variable3 as a textfile


    (I'm a newbie and that's just my first thought )
    [vbcode]
    On Error GoTo Hell
    [/vbcode]:¬) Nicky : Why not try VBCodebook.NET.

  3. #3

    Thread Starter
    Member
    Join Date
    Nov 2002
    Location
    Austria
    Posts
    52
    thanks... yes that's how it could work but that way i have to write the file twice.

    what i want to do is to
    1. write the file
    2. encode the file
    3. add the header (not encoded)

    the file can be realy large... so i have to modify it. i've used the filestream object and when i debug the program it seems to do what i want... but when i look into the file there's no header

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