Windows API Guide - Reference - Volume 1: Version 3.0 For the MS-DOS and PC-DOS Operating Systems
Declare Function SHUpdateRecycleBinIcon Lib "shell32.dll" () As Long
Platforms
- Windows 95: Requires Internet Explorer 4.0 with integrated shell installed.
- Windows 98: Supported.
- Windows NT: Requires Windows NT 4.0 or later and Internet Explorer 4.0 or later with integrated shell installed.
- Windows 2000: Supported.
- Windows CE: Not Supported.
Description & Usage
SHUpdateRecycleBinIcon updates the Recycle Bin icon on the desktop to reflect the state of the systemwide Recycle Bin. Since the other Recycle Bin management functions will update this icon on their own, there's almost no reason why your applications would need to call this function explicitly.
Return Value
If an error occued, the function returns a non-zero error code. If successful, the function returns 0.
Visual Basic-Specific Issues
None.
Parameters
None.
Example
' This code is licensed according to the terms and conditions listed here. ' Delete the contents in the system's Recycle Bin, without ' showing the progress dialog. If an error occurs, be safe and ' make sure the proper Recyle Bin icon is used. Dim retval As Long ' return value ' Delete the contents of the system's Recycle Bin, if the user OKs it. retval = SHEmptyRecycleBin(Form1.hWnd, "", SHERB_NOPROGRESSUI) ' If an error occured, be overly save and refresh the Recycle Bin ' icon. This probably isn't necessary, however. If retval <> 0 Then ' error retval = SHUpdateRecycleBinIcon() End If
See Also
SHEmptyRecycleBin
Category
Shell
Go back to the alphabetical Function listing. Go back to the Reference section index.
Last Modified: September 1, 1999 This page is copyright © 1999 Paul Kuliniewicz. Copyright Information Revised October 29, 2000 Go back to the Windows API Guide home page. E-mail: vbapi@vbapi.com Send Encrypted E-Mail This page is at http://www.vbapi.com/ref/s/shupdaterecyclebinicon.html