I am writing a perl script which I want to have platform independent.

The over-all scope of the script is to pull in an xml doc, parse it and
do group membership lookups against a variety of back-end systems. I
have currently coded ( and gotten working ) standard unix getent and
lookups against windows via Win32::Ole.

I am trying to change the use to a require:

sub ResolveViaWin32 {
(...)
    BEGIN {
      require Win32::OLE or die "failed to require Win32::OLE: $!\n";
      import Win32::OLE 'in' or die "failed to import in: $!\n";
    }
(...)
}

The require works, the import fails. My use ( use Win32::OLE 'in'; )
works great.

Is there another way to accomplish this which I have just not found yet?

-- 

Bill Schwanitz

An eye for an eye makes the whole world blind.
   - Mahatma Gandhi
begin:vcard
fn:Bill Schwanitz
n:Bill;Schwanitz
email;internet:[EMAIL PROTECTED]
x-mozilla-html:FALSE
url:http://http;//bilsch.org
version:2.1
end:vcard

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Perl-Win32-Admin mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to