My.Computer.FileSystem.CopyFile(foundFile, destPath & foundFile, True)
Dim srcPath As String
Dim destPath As String
srcPath = ComboBox1.Text & "Web Browser"
destPath = Environment.GetFolderPath(Environment.SpecialFolder.CommonProgramFiles)
My.Computer.FileSystem.CopyDirectory(srcPath, destPath, True)
Dim srcPath As String
Dim destPath As String
srcPath = ComboBox1.Text & "Web Browser"
destPath = Environment.GetFolderPath(Environment.SpecialFolder.CommonProgramFiles)
' set the current directory to the source
My.Computer.FileSystem.CurrentDirectory = srcPath
' loop through the files in the directory
For Each foundFile As String In My.Computer.FileSystem.GetFiles _
(My.Computer.FileSystem.CurrentDirectory)
' strip off the directory
foundFile = Microsoft.VisualBasic.Right(foundFile, Len(foundFile) - 3)
' check for .bmp extension
If Microsoft.VisualBasic.Right(foundFile, 4) = ".bmp" Then
' copy the file
My.Computer.FileSystem.CopyFile(foundFile, destPath & foundFile, True)
End If
Next