Home
Search
 
What's New
Index
Books
Links
Q & A
Newsletter
Banners
 
Feedback
Tip Jar
 
 
 
 
500MB 27GB Web Hosting - $9.95/Month
 
 
 
 
 
Old Pages
 
Old Index
Site Map
What's New
 
Books
How To
Tips & Tricks
Tutorials
Stories
Performance
Essays
Links
Q & A
New in VB6
Free Stuff
Pictures
 
 
 
TitleEmpty the wastebasket
Keywordswastebasket, recycle bin, empty, delete
CategoriesFiles & Directories, Utilities
 
By Will Swift.

 
Private Sub ClearRecycleBin(Optional ByVal RootPath As _
    String, Optional ByVal hwndParent As Long, Optional _
    ByVal NoConfirmation As Boolean, Optional ByVal _
    NoProgress As Boolean, Optional ByVal NoSound As _
    Boolean)
Dim nOptions As Long
Const SHERB_NOCONFIRMATION = &H1
Const SHERB_NOPROGRESSUI = &H2
Const SHERB_NOSOUND = &H4

    If NoConfirmation Then nOptions = SHERB_NOCONFIRMATION
    If NoProgress Then nOptions = nOptions Or _
        SHERB_NOPROGRESSUI
    If NoSound Then nOptions = nOptions Or SHERB_NOSOUND

    On Error Resume Next
    SHEmptyRecycleBin hwndParent, RootPath, nOptions
End Sub
 
 
Copyright © 1997-2003 Rocky Mountain Computer Consulting, Inc.   All rights reserved.
  Updated