Skip to content

Commit

Permalink
A VBScript file to move dll's from the thirdparty directory into bin\…
Browse files Browse the repository at this point in the history
…debug
  • Loading branch information
unknown committed Mar 22, 2011
1 parent 66617aa commit 9553214
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions Win32/VS2010/copydll.vbs
@@ -0,0 +1,30 @@
' Program to recursively copy dll files from the thirdparty directory into bin\debug
' Robert Kulagowski, 2011-03-22
' Cobbled together from examples on the web

option explicit

Dim strStartFolder, strDestinationFolder, objFSO, objFolder, strFilenames, objSubFolder, objSubFile
Dim colFolders, objFile

strStartFolder = "thirdparty"
strDestinationFolder = ".\bin\debug\"

Set objFSO = CreateObject("Scripting.FileSystemObject")

Set objFolder = objFSO.GetFolder(strStartFolder)

ScanSubFolders(objFolder)

Sub ScanSubFolders(objFolder)
Set colFolders = objFolder.SubFolders
For Each objSubFolder In colFolders
Set strFilenames = objSubFolder.Files
For Each objFile in strFilenames
If lcase(Right(objFile.Name,3)) = "dll" Then
objFSO.CopyFile objFile,(strDestinationFolder)
End If
Next
ScanSubFolders(objSubFolder)
Next
End Sub

0 comments on commit 9553214

Please sign in to comment.