Re: write/read to/from file problem
- From: usenet@xxxxxxxxxxxxxxx
- Date: 31 May 2006 13:42:19 -0700
dd007 wrote:
But when I use same lines of code in my exisitng
script, data.txt does not get created. Does someone know why?
Perl probably knows why. Instead of speculating (or asking us to
speculate), why don't you simply have Perl tell you why it cannot do
the operation?
open (MYFILE, '>>data.txt') or die "Cannot open file: $! \n";
print MYFILE "Bob\n" or die "Cannot print: $! \n";
close (MYFILE) or die "Cannot close (huh?): $! \n";
--
David Filmer (http://DavidFilmer.com)
.
- Follow-Ups:
- Re: write/read to/from file problem
- From: dd007
- Re: write/read to/from file problem
- References:
- write/read to/from file problem
- From: dd007
- write/read to/from file problem
- Prev by Date: write/read to/from file problem
- Next by Date: Re: write/read to/from file problem
- Previous by thread: write/read to/from file problem
- Next by thread: Re: write/read to/from file problem
- Index(es):
Relevant Pages
|
|