VBScript » FileSystemObject » GetFolder

Version: 2.0

Syntax:
object.GetFolder (foldername)

This method returns a Folder object of the folder specified in the folder parameter.

You can than use the new variable containing the folder object to access its various methods and properties. The following code demonstrates this by returning the date the folder was created and displaying the details in the browser.

Examples

Code:
<%
dim filesys, f
Set filesys = CreateObject("Scripting.FileSystemObject")
Set f = filesys.GetFolder("C:\TestFolder\")
Response.Write ("Your folder was created on " f.DateCreated)
%>
Output:
"Your folder was created on (date created goes here)."