in reply to Dynamic Code?

You can do that... but that's not normal Perl code. :) There's no "then" statement in Perl, and you'll need to do something with those arguments.

The secret is the string form of eval:

my $a = 'somesub($arg1, $arg2) if $joe'; eval $a;

Replies are listed 'Best First'.
RE: Re: Dynamic Code?
by kael (Monk) on Aug 26, 2000 at 03:00 UTC
    it was 3 am give me a break :) though I haven't used then since my TP days like 5 years ago...
    Thanx for the help everyone. now I get to fiddle and make it work