PowerBook 520c, 7.6.1, Perl 5.2.0r4. As you can see from the "File '<AppleEvent>'", I ran these from the "Run MacPerl Front" BBEdit tool menu. Can anyone help me explain this? TIA! -Stewart This program: --------------------------------- #!/bin/perl -w use strict &DoInits(); print "pathSep=$pathSep\n"; exit; sub DoInits { $pathSep = ':'; } #End of DoInits -------------------------------- Gets this result: --------------------------------- # Undefined subroutine &main::DoInits called. File '<AppleEvent>'; Line 5 # BEGIN failed--compilation aborted. File '<AppleEvent>'; Line 5 -------------------------------- And THIS program: --------------------------------- #!/bin/perl -w use strict #$x = '1'; <==== Added line &DoInits(); print "pathSep=$pathSep\n"; exit; sub DoInits { $pathSep = ':'; } #End of DoInits -------------------------------- Gets this result: --------------------------------- # Undefined subroutine &main::DoInits called. File '<AppleEvent>'; Line 6 # BEGIN failed--compilation aborted. File '<AppleEvent>'; Line 6 -------------------------------- BUT... this program: --------------------------------- #!/bin/perl -w use strict $x = '1'; <==== Changed line &DoInits(); print "pathSep=$pathSep\n"; exit; sub DoInits { $pathSep = ':'; } #End of DoInits -------------------------------- WORKS! and gets this result: --------------------------------- # Name "main::x" used only once: possible typo. File '<AppleEvent>'; Line 5 pathSep=: -------------------------------- --- Stewart Leicester "Ad Astra StewartL@JenSoft.com JenSoft Technologies Per Aspera" 925/551-0130 ***** Want to unsubscribe from this list? ***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch