On Jan 2, 2:33 am, chas.ow...@gmail.com (Chas. Owens) wrote:
> On Thu, Jan 1, 2009 at 17:12, Collaborate <tolg...@yahoo.com> wrote:
> > On Jan 1, 3:46 pm, nore...@gunnar.cc (Gunnar Hjalmarsson) wrote:
> >> Collaborate wrote:
> >> > After wiriting the output of a Perl program to a text file, I'd like
> >> > to immediately open (display the contents of) that text file from
> >> > within the code so I can see what's in the file. I am wondering if
> >> > there is a simple way to accomlish this. Thanks.
>
> >> How about simply printing the output to STDOUT as well?
>
> >> --
> >> Gunnar Hjalmarsson
> >> Email:http://www.gunnar.cc/cgi-bin/contact.pl
>
> > Sending to SDTOUT is good for checking the output however there are
> > cases when there is formatting included in the output file. I am in
> > particular interested in seeind the contents of a file by opening it
> > from within the code.
>
> snip
>
> Okay, you seem to be making contradictory statements: you are writing
> a text file (which by definition has no formatting) and you have some
> cases where there is formatting included in the output file.  Since it
> sounds like you are not dealing with a normal ASCII or UTF-8 text
> file, what is actual format of the file you are dealing with?  You can
> always open a file with the open function (as I demonstrated), but if
> you are working with a specific format of data you will most likely
> want to use a module that already knows how to process that format to
> read the data into a data structure that preserves the structure of
> the data.
>
> --
> Chas. Owens
> wonkden.net
> The most important skill a programmer can have is the ability to read.- Hide 
> quoted text -
>
> - Show quoted text -


I should have stated my question in a more general sense. I can send
the output to a text or an Excel file. Other file formats that I
haven't yet explored may be possible. Instead of double clicking with
the mouse on the created file's name to see what's in the file, I'd
like the program to simulate the double clicking even. I was wondering
if Perl can "open" a file, regardless of the file type.


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to