Perl Win32::API无法加载Win32 dll

Perl Win32::API无法加载Win32 dll,perl,perl-module,activeperl,Perl,Perl Module,Activeperl,我正在尝试使用Win32::API模块在perl脚本中使用Win32 dll。 为此,我编写了这样一个perl脚本 use Win32::API; $Win32::API::DEBUG = 1; $function = Win32::API->new( 'mydll.dll', 'int func()', ); $return = $function->Call(); 但我得到了以下错误: Win32::API::new: Loading library 'mydll.dll'

我正在尝试使用Win32::API模块在perl脚本中使用Win32 dll。 为此,我编写了这样一个perl脚本

use Win32::API;
$Win32::API::DEBUG = 1;
$function = Win32::API->new(
  'mydll.dll', 'int func()',
);
$return = $function->Call();
但我得到了以下错误:

Win32::API::new: Loading library 'mydll.dll'
FAILED Loading library 'mydll.dll': The specified module could not be found.
Can't call method "Call" on an undefined value at .\test_dll.pl line 6.
虽然脚本和dll位于同一位置,但它不可能找不到dll。我还尝试使用完整路径

我正在Windos7平台上使用ActivePerl5.16。我也用5.14试过了,没有任何帮助


这里发生了什么?

在将其他依赖DLL添加到原来的位置后,此问题得到解决