[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] I have a question...



At 03.43 98.01.13, Blitz80690 wrote:
>A little background about myself before the rest of you laugh at my problem.
>I am a 19 year old without much background in programming, trying to teach
>myself MacPerl as my *FIRST* programming/scripting language, while going to
>college for an associates in programming.

Sounds great!

>First of all, I was wondering if
>there was a beginner or intermediate mailing list for MacPerl, and if there
>are beginners who have made some scripts that other beginners could use as
>examples for their learning?

Well, there are a few things you can do.  First, beginer questions are
perfectly welcome here, as long as they are specific to MacPerl, and not
Perl or programming in general.  The Usenet group comp.lang.perl.misc is a
good resource, if not unweildy.  And my upcoming book with Vicki Brown,
_MacPerl: Power and Ease_, should be of use to you as well.  Draft chapters
are available online at the URL in my .sig.

>Anyways, I have tried to teach myself to open
>files and write to files this past weekend.  I learned how to open files after
>about five hours at looking at the same example over and over.  This is the
>first time I have tried to write a file and then open it.  Here is my script
>so far.

>And it works just fine, except that it gives me these errors:
>
># Use of uninitialized value, <STDIN> chunk 2.
>File ':StandardFile.pl'; Line 38
># Use of uninitialized value, <STDIN> chunk 2.
>File ':StandardFile.pl'; Line 42
># Use of uninitialized value, <STDIN> chunk 2.
>File ':StandardFile.pl'; Line 48
># Use of uninitialized value, <STDIN> chunk 2.
>File ':StandardFile.pl'; Line 48
>
>
>Which I don't understand completely, because the script doesn't even have 38
>lines.  Can you help me here?  What am I doing wrong?  Have I not declared a
>variable with StandardFile.pl?

:)  This is not your fault, actually, but the fault of the StandardFile.pl
library, which was written for an older version of MacPerl and is not
completely clean with -w on.  The good news is that this is just a warning,
and aside from the noise is probably not going to mean anything bad.

FYI, the "Diagnostic messages" item under Help should list every help
message that Perl returns.

>Just in case you ask, I have the MacPerl application, StandardFile.pl, and
>GUSI.ph in the directory that I tell the person running the script to get
>hello.txt
>
>Also, after all of those errors, the script lets me get the file, and opens it
>just fine, displaying the text.
>
>Please help!!!

Looks like you did a pretty good job.  Cheers!


>P.S.   I'm sorry that you have to read such sloppy code, but remember i'm just
>a beginner....

Don't worry, if you stick with it, it _will_ get better.  :)

--
Chris Nandor               pudge@pobox.com           http://pudge.net/
%PGPKey=('B76E72AD',[1024,'0824 090B CE73 CA10  1FF7 7F13 8180 B6B6'])
#==                    MacPerl: Power and Ease                     ==#
#==    Publishing Date: Early 1998. http://www.ptf.com/macperl/    ==#



***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch