On Mon, Feb 23, 2004 at 11:29:50AM +0000, Gary Stainburn wrote: > Is there a way to only 'use Trainset::Tk' conditionally, or even better, have > it auto-detect the availability and simply ignore it if it's not there.
I do that in the following fashion: BEGIN { eval "use Trainset::Tk" } # We'll use this if it is available. my $tk_available = $INC{"Trainset/Tk.pm"}; if ($tk_available) { } -- Paul Johnson - [EMAIL PROTECTED] http://www.pjcj.net -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>