Perl - Script to retrieve remote Windows server file version info

Just migrated to an ActiveState Perl distro (5.28) and new to the Perl community. I’m looking for something that does what is shown in the below code snippet, however, when I attempt to execute this, I get the following error message. How would I resolve this

Can’t locate Win32/File/ in @INC (you may need to install the Win32::File::VersionInfo module) (@INC contains: e:/Perl64/site/lib e:/Perl64/lib)

use Win32::File::VersionInfo;
my $foo = GetFileVersionInfo (“C:\path\to\file.dll” );
if` ( $foo ) {
print $foo->{FileVersion}, “\n”;
my $lang = ( ( keys %{$foo->{Lang}} )[0] );
if ( $lang) {
print $foo->{Lang}{$lang}{CompanyName}, “\n”;


Win32-File-VersionInfo is an optional module. To get it in the installer for your project, you can use the Add Packages tab on the Configuration pane, search for Win32-File-VersionInfo, and then select the version to use or allow the solver to make a best fit.

Add Packages is described in several places in the manuals. Here is one of those:

This solved the issue. Thanks much!