Re: Write the output to a file

2007-12-13 Thread Dermot
On 12/12/2007, Chas. Owens <[EMAIL PROTECTED]> wrote: > > On Dec 12, 2007 7:08 AM, Dr.Ruud <[EMAIL PROTECTED]> wrote: > > > Your last comment line ("it will close here") I would put inside the > > block, or I would say "is closed with the block". > > (I am all for lexical comments.) > snip > > I ca

Re: Write the output to a file

2007-12-12 Thread Chas. Owens
On Dec 12, 2007 7:08 AM, Dr.Ruud <[EMAIL PROTECTED]> wrote: > "Chas. Owens" schreef: snip > > } #unless a reference was made to $fh it will close here snip > Your last comment line ("it will close here") I would put inside the > block, or I would say "is closed with the block". > (I am all for lexi

Re: Write the output to a file

2007-12-12 Thread Dr.Ruud
"Chas. Owens" schreef: > Dr.Ruud: >> Chas. Owens: >>> (you should close file handles once you >>> stop using them because they are a limited resource). >> >> I often start a new block at opening a file. > > If you are using the new scalar based file handles this is a good > practice since they aut

Re: Write the output to a file

2007-12-12 Thread Chas. Owens
On Dec 12, 2007 4:46 AM, Dr.Ruud <[EMAIL PROTECTED]> wrote: > "Chas. Owens" schreef: > > > (you should close file handles once you > > stop using them because they are a limited resource). > > I often start a new block at opening a file. snip If you are using the new scalar based file handles this

Re: Write the output to a file

2007-12-12 Thread Dr.Ruud
"Chas. Owens" schreef: > (you should close file handles once you > stop using them because they are a limited resource). I often start a new block at opening a file. -- Affijn, Ruud "Gewoon is een tijger." -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL

Re: Write the output to a file

2007-12-11 Thread Chas. Owens
On Dec 11, 2007 2:10 AM, patmarbidon <[EMAIL PROTECTED]> wrote: > Patrick Marion has written: > I think that your 'close (OUTPUT)' is inside the sub 'pits' > > you might put it before 'sub pits {' to get it at the logiccal end of > your program. snip Or remove the close completely. Perl closes al

Re: Write the output to a file

2007-12-11 Thread John W . Krahn
On Monday 10 December 2007 21:50, John Jack wrote: > > Hi Group Hello, > I'm new to perl and haven't used it before. I'm still practising and > trying my best to know it. Anyway, I wanted to print the list of > files in a directory with their full pathnames. This script below > worked fine but I

Re: Write the output to a file

2007-12-10 Thread patmarbidon
Patrick Marion has written: I think that your 'close (OUTPUT)' is inside the sub 'pits' you might put it before 'sub pits {' to get it at the logiccal end of your program. John Jack has written : Hi Group I'm new to perl and haven't used it before. I'm still practising and trying my best to

Write the output to a file

2007-12-10 Thread John Jack
Hi Group I'm new to perl and haven't used it before. I'm still practising and trying my best to know it. Anyway, I wanted to print the list of files in a directory with their full pathnames. This script below worked fine but I want to write it to a file. Can someone help me, please? I know it must