monks007 has asked for the wisdom of the Perl Monks concerning the following question:

Hi All,

Please see my below code.

________________________________________________

my $dir = $ARGV[0]; #Getting command line argument (path of the file) foreach $file (<$dir*.xml>) # Error here when i run exe only.

_________________________________________________

In my above code, as a pl file working fine, But after convert into exe it's not working. Please suggest.

Thanks monks007

Edit: g0n - code tags

Replies are listed 'Best First'.
Re: .pl working fine but .exe not works
by marto (Cardinal) on Oct 03, 2007 at 08:24 UTC
    Hi monks007,

    Please take a look at the PerlMonks FAQ and How do I post a question effectively? if you have not already done so. You could help us out a lot by posting all of your Perl code, or a reasonable snippet, and a description of how you are creating the exe, and the error message you receive when running the executable.

    P.S. Also take a look at Writeup Formatting Tips, a link to this is displayed prior to posting here.

    Martin
Re: .pl working fine but .exe not works
by erroneousBollock (Curate) on Oct 03, 2007 at 08:07 UTC
Re: .pl working fine but .exe not works
by Gangabass (Vicar) on Oct 03, 2007 at 08:53 UTC

    "Not working" how? How you see that code not working?

    A reply falls below the community's threshold of quality. You may see it by logging in.
Re: .pl working fine but .exe not works
by perlfan (Parson) on Oct 03, 2007 at 13:18 UTC
    You'll probably have to wrap it around a dos batch script or simply call it as perl yourfile.pl ...