in reply to pp/prima problem

There are two modules out there Prima::Buttons and Tk::Button
Be sure you have installed what you need
Just
ppm> install Prima::Buttons ppm> install Tk::Button

If the answer is 'the module is allready installed' then you have the modules.
But if you say that you get 'Can't locate Prima/Buttons.pm in @INC' then probably you don't have it.
Or you do but in the wrong location. Do a file search for it and if you do have it then use on top of your script

push (@INC, "/location/of/module");

But this is not the right solution. The right one is to install it in the right location, where every module is.

``The wise man doesn't give the right answers, he poses the right questions.'' TIMTOWTDI

Replies are listed 'Best First'.
Re^2: pp/prima problem
by c6ackp (Novice) on May 30, 2005 at 18:45 UTC
    Thanks for the replies.

    The modules are all installed ok because the scripts work correctly from the command box and also when I execute them in Eclipse.

    It's a pp related problem - here's the full error message:

    C:\DOCUME~1\STEVE\MYDOCU~1\JAVA\ECLIPSE\ECLIPSE\WORKSP~1\PERLTEST>a.ex +e Can't locate Prima/Buttons.pm in @INC (@INC contains: CODE(0xcb9f60) C +ODE(0xda9a b8) .) at (eval 48) line 1. BEGIN failed--compilation aborted at (eval 48) line 1. BEGIN failed--compilation aborted at script/prima_pointer.pl line 9.
    Does "@INC contains: CODE(0xcb9..." suggest that @INC is being corrupted when the exe fires up?
      Does "@INC contains: CODE(0xcb9..." suggest that @INC is being corrupted when the exe fires up?
      No. It's a way to have smart libraries: by including a callback (a code ref) in @INC. See require:
      You can also insert hooks into the import facility, by putting directly Perl code into the @INC array. There are three forms of hooks: subroutine references, array references and blessed objects.
      (You can read the rest there.)

      What happens, is IMO that pp didn't know that Prima::Buttons is needed, so it didn't include it. Probably, that happens because the module gets required dynamically, I guess it could likely happen with DBD::* modules for DBI, too.

      See the docs for pp, command line option -M:

      % pp -M Foo::Bar hello # Extra modules in the include path