Re: Can't find string terminator "EOM" - beginner question



humphrey.c.chan@xxxxxxxxx <humphrey.c.chan@xxxxxxxxx> wrote:

> I am getting the following error message when running my program :
>
> Can't find string terminator "EOM" anywhere before EOF at ./my-prog.pl
> line 107.

> Here's my program excerpt -->>


> 107 print <<EOM;
> 108 From: sa@xxxxxxxxxxx
> 109 To: user1@xxxxxxxxxxx
> 110
> 111 Subject: Alert !! Alert !!
> 112
> 113
> 114 Please check the system
> 115 at your earliest convenience......
> 116
> 117 PS: You know who you arev !!
> 118
> 119
> 120 EOM
^
^ looks like there is a space character there...

> Plesae help me to resolve the problem.


Remove the space character infront of the EOM, it must be
flush to the left margin.

(or, insert a space when you specify the terminator: print <<" EOM"; )


--
Tad McClellan SGML consulting
tadmc@xxxxxxxxxxxxxx Perl programming
Fort Worth, Texas
.



Relevant Pages