• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Re: Write to file
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Re: Write to file


  • Subject: Re: Re: Write to file
  • From: email@hidden
  • Date: Tue, 27 Feb 2001 17:42:21 EST

>On 2/27/01 9:26 AM, Sander Tekelenburg <email@hidden> wrote:
>
>>Be careful. This will just start writing at the beginning of the file
without
>>any regard for what the file already contains. If the variable "mydata"
>>happens to contain less data then your file "foo", you'll end up with "foo"
>>containing your new data, followed by some leftovers.

and Michelle Steiner responded

>Doesn't write reset EOF automatically?

No, and thank goodness. Can you imagine a multi-megabyte text file into the
middle of which you want to write a small string? While it may be useful to
load the entire text file into a variable, work with it, and re-write en
bloc, many times that proves unwieldy, and direct writing to the file is
easier. You don't want to trash half your data doing it that way.

Jeff Baumann
email@hidden
www.linkedresources.com

14 Days, 14 Hours, 36 Minutes
How is it going to end?


  • Prev by Date: Write to file - another question
  • Next by Date: Handler joy
  • Previous by thread: Re: Write to file
  • Next by thread: Re: Write to file
  • Index(es):
    • Date
    • Thread