in reply to Re: Win32::API question
in thread Win32::API question

my $Api = new Win32::API("fileversion.dll", "GetFileVersionTxt", P, P) +;
should be changed to
my $Api = new Win32::API("fileversion.dll", "GetFileVersionTxt", ['P', + 'P'], 'I');
or
my $Api = new Win32::API("fileversion.dll", "GetFileVersionTxt", 'PP', + 'I');
The third parameter is suposed to be a string or array ref of the input parameters, and the forth is a string for the return value.

Replies are listed 'Best First'.
Re: Re: Re: Win32::API question
by Ninthwave (Chaplain) on Jun 02, 2004 at 19:36 UTC

    Cheers I alway forget the single quotes.

    I usually catch errors like that if I test code. But I was running from work without a dll to use. Oh well, maybe next time my first reply will be better ;)
    But than Win32::API for me is always sitting with a sample and changing it to meet my needs based on the functions called. Funny enough to see what got added to the meditations How to make Win32::API easy to use

    "No matter where you go, there you are." BB