in reply to Re: Tk interface and the rest of the program -- II
in thread Tk interface and the rest of the program -- II

Hi kvale,

So in myscript.pl, I should have something like

my $filename = @_;


in order to access $filename from the Tk interface?

Thank you so much!

Replies are listed 'Best First'.
Re: Re: Re: Tk interface and the rest of the program -- II
by kvale (Monsignor) on Aug 15, 2002 at 21:22 UTC
    Your statement assigns an array to a scalar, not what you want. To extract the subroutine parameter, use
    my $filename = shift;
    This shifts the first element off of @_ and assigns it to $filename.

    -Mark