Update CopyGoogleChromeBookmarks.vbs
Added File Existence Check
This commit is contained in:
6
Microsoft/Windows/CopyGoogleChromeBookmarks.vbs
Executable file → Normal file
6
Microsoft/Windows/CopyGoogleChromeBookmarks.vbs
Executable file → Normal file
@@ -1,7 +1,9 @@
|
||||
' CopyGoogleChromeBookmarks.vbs - Copy Bookmarks File of Google Chrome to HomeDir
|
||||
' and retain the last 14 Files (by Creation Date)
|
||||
' Run from AppSense
|
||||
|
||||
' v1.0 - 29.10.2022 - Initial Release
|
||||
' v1.1 - 30.10.2022 - Added Files Existence Check
|
||||
|
||||
' WSHShell
|
||||
Dim objWSH
|
||||
@@ -31,8 +33,10 @@
|
||||
objFSO.CreateFolder strBackupFolder
|
||||
End If
|
||||
|
||||
' Copy File
|
||||
' Copy File if it exists
|
||||
If objFSO.FileExists(strProfileFolder & strBackupFile) Then
|
||||
objFSO.CopyFile strProfileFolder & strBackupFile, strBackupFolder & strActualBackupFile
|
||||
End If ' FileExists
|
||||
|
||||
' Only run if we actually have more than 14 files...
|
||||
Dim objFolder
|
||||
|
||||
Reference in New Issue
Block a user