How to get the creation date & time of a particular file
Set f1 = CreateObject(“Scripting.FileSystemObject”) Set f2 = f1.GetFile(“D:QTP_TESTtest.docx”) S = “File was Created on: “&f2.DateCreated Msgbox S
Set f1 = CreateObject(“Scripting.FileSystemObject”) Set f2 = f1.GetFile(“D:QTP_TESTtest.docx”) S = “File was Created on: “&f2.DateCreated Msgbox S
Let’s assume, we have D:PFolder where 3 subfolders present named as sun1, sun2 & sun3 We will use FileSystemObject as class name to deal with folders. Set a = CreateObject(“Scripting.FileSystemObject”) Set b = a.GetFolder(“D:QTP_TEST”) Set c = b.SubFolders For Each d in c e=e&d.name&vbnewline Next msgbox e