there are a way to clean all file with vb?
i know the api function for this but i didn't know how to use it.
Anyone know how to use this api function to clean recycle bin???
Try This Following Code :
private declare function SHEmptyRecycleBin Lib "shell32.dll" Alias "SHEmptyRecycleBinA" (ByVal hwnd As Long,ByVal pszRootPath As String,ByVal dwFlags As Long) As Long Private Const SHERB_NORMAL = &H10 Private Const SHERB_NOCONFIRMATION = &H1 Private Const SHERB_NOPROGRESSUI = &H2 Private Const SHERB_NOSOUND = &H4 Private Const SHERB_NOALL = _ (SHERB_NOCONFIRMATION And _ SHERB_NOPROGRESSUI And SHERB_NOSOUND) Dim RetVal As Long Private Sub Command1_Click() Dim y as Integer y = MsgBox("Are u sure to clean up Recycle Bin ? ", vbYesNo, "Confirmation" If y = vbYes Then RetVal = SHEmptyRecycleBin(0&,vbNullString,&H1) MsgBox "Recycle Bin has been cleaned" End If End Sub
Ok. Hope This Helps.
check this sample and give your feedback
thx jx_man its working nice. :)
thanks Shouvik for your example program. :)
how can i zip and unzip a file using SharpzipLib.Dll.
Can any one help me?.
Thanks in advance...
Ok. Happy coding friend :)
you are welcome