Micro Focus QTP (UFT) Forums
Scripts back up - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: Scripts back up (/Thread-Scripts-back-up)



Scripts back up - Sathiya - 09-07-2011

Hi Friends
i want back up of my scripts in qc and want to save in local pc.
here is the code for copying between folders in the local pc
Code:
dim filesys, newfolder, newfolderpath
Dim dateformat
dateformat = replace(now, "/", "-")
dateformat = replace(dateformat, ":", "-")
msgbox dateformat
newfolderpath = "D:\Sathiya\Backup\"&dateformat
' dataformat is just to identify on which date back up is taken.
set filesys=CreateObject("Scripting.FileSystemObject")
If filesys.FolderExists("D:\sathiya\BNFS\sathiya\Qtp practice\comparing two excel sheet\Comapring_two_excel_sheets" ) Then
Set newfolder = filesys.CreateFolder(newfolderpath)
filesys.CopyFolder "D:\sathiya\BNFS\sathiya\Qtp practice\comparing two excel sheet\Comapring_two_excel_sheets", newfolderpath
End If


Kindly helps in this regard