Contact Us

Scripts: asp :: ASP File System :: Library Article #1

Developer's Section

Creating a File in ASP
By: Erobo Team Member

Hire a Developer for Related Work / Installation | $55 hr
Rating:  | Rate It:   
Average Votes: (3141)

Read how to create a file in ASP.

It is very easy to create a simple file in ASP. Just create an object of type FileSystemObject from the Scripting library like this:

 Code Snippet 1

Dim fileObject
Dim thisFile
Dim filePath
Set fileObject =Server.CreateObject("Scripting.FileSystemObject")
filePath = Server.Mappath("files/myfile.txt")
Set thisFile = fileObject.GetFile(filePath)
Response.Write("File Name: " & thisFile.Name & "<br>" & vbCrlf)
Response.Write("File Path: " & thisFile.Path & "<br>" & vbCrlf)
set fileObject=nothing
set thisFile=nothing

See other Scripts in ASP File System

Submit Your Scripts:

If you would like to have your ASP & ASP.NET scripts published in this section please fill out
the form below:
*Your Name or Username:
Home Town:
*Description and Code:
*Enter Code shown
to the right:

[ Refresh Image ]