Jenda is correct. change the 'package Win32::GUI::CardLayout' to 'package
CardLayout' in the .pm file.
Change the 'require Win32::GUI::CardLayout' to 'require CardLayout' in the .pl
file and make sure that both are in the same directory.
this will fix it so that you can use it.
P.S. - what did I do wrong? I wanted to be able to put the module in the
d:\perl\site\lib\win32\gui so that the Win32::GUI organization remains. I just
thought that I may not have had some setting on my machine set correctly....
evidently I did something wrong.... but what??
Thanks.
Jenda Krynicky wrote:
> > When trying to run this script I got the following error
> > Can't locate object method "new" via package "CardLayout" at Cardlayout.pl
> > line 12.
> >
> > Line 12 = $card1 = new CardLayout($Window, "main");
> >
> > What is wrong ?
> >
> > TIA,
> >
> > Jorn
> >
> > p.s. I placed CardLayout.pm in the directory: c:\perl\site\lib\win32\GUI
>
> $card1 = new Win32::GUI::CardLayout($Window, "main");
>
> The module originaly was CardLayout, but I think all those should be
> UNDER Win32::GUI.
>
> Also review if the first line of the module is
>
> package Win32::GUI::CardLayout;
> and not
> package CardLayout;
>
> Jenda
> == [EMAIL PROTECTED] == http://Jenda.Krynicky.cz ==
> The phenomenon of UFO doesn't say anything about
> the presence of intelligence in space.
> It just shows how rare it is here on the earth.
> A.C.Clarke
--
Michael Kangas
Anlon Systems, Inc.
[EMAIL PROTECTED]