Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: Win32::API - How to call an Imported function with Win32::API::Types ?

by vladdrak (Monk)
on Jul 02, 2004 at 02:35 UTC ( #371285=note: print w/replies, xml ) Need Help??


in reply to Win32::API - How to call an Imported function with Win32::API::Types ?

This may not be of great help, but I've always used Win32::API a bit differently, (not importing) which worked for me. You're out there in no mans land with Win32::API for the most part, doc/example-wise, so I hope you have some C under you belt. Try packing up your stuff proper, minus the typedefs, and just shove it in there.

Warning: you may have to sacrifice livestock or perform some strange ritual in a musty basement in order to get everything working.

-vlad
my $FileTimeToSystemTime = new Win32::API('Kernel32.dll', 'FileTimeToS +ystemTime',['P','P'],'I'); sub FileTimeToSystemTime { my $filetime=shift; my $systemtime="\0" x (2*8); $FileTimeToSystemTime->Call($filetime, $systemtime) or return; return unpack( 'S8', $systemtime); }
  • Comment on Re: Win32::API - How to call an Imported function with Win32::API::Types ?
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://371285]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (5)
As of 2023-01-31 11:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?