Passing NULL pointer to Win32::API function 
Author Message
 Passing NULL pointer to Win32::API function

I am trying to empty my recycle bin by using the SHEmptyRecycleBin()
function using Win32::API. How do I pass a NULL pointer parameter to
this function (the second parameter)? According to the docs for
SHEmptyRecycleBin() if it is NULL or an empty string then it will
empty all contents of the recycle bin. But in the code below setting
$null to an empty string ($null = "") does not work.

Regards,
Diego Barros

use Win32::API;
$SHEmptyRecycleBin = new Win32::API( "shell32", "SHEmptyRecycleBin", [
N, P, N ], N );
$null = ???;
$SHEmptyRecycleBin->Call( 0, $null, 0 );
$SHEmptyRecycleBin = undef;



Thu, 01 Nov 2001 03:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Passing NULL pointers to Win32::API function

2. Passing NULL pointer to Win32::API function

3. Passing null BSTR pointer with Win32::OLE

4. Newbie: passing a null string to a Win32 api call

5. Win32::API -- how to call functions using NULL pointers?

6. Win32::API and Novell DLL Pointers

7. Win32::API and a pointer in a structure

8. function parameter passing, null arg distinction

9. Passing a pointer to C function ?

10. Passing File Handles when using Win32::API

11. Win32::API - passing unicode string?

12. WIN32::API - how to pass char * const

 

 
Powered by phpBB® Forum Software