web tools rank checker

domain .cn
.net .cn .com.cn
你正在阅览 :: 简体中文:: 学习 ASP SQL VB HTML code

学习 .ASP SQL HTML XML CSS JAVA Perl code study
English Chinese_Traditional Chinese_Simplified

你正在阅览 :: 简体中文 Chinese_Simplified

学习.主题:
首页
ASP
. Active-Server-Flash
. Array
. Connection
. Count
. Counter
. Distinct
. Email
. File
»Create
»delete
»File-obj-Count
»Move
»ReadAll-ReadLine
»Server.MapPath
. Folder
. Function
. GetSQLserver
. Header
. mySQL
. Record
. Recordset
. Request
. Response
. Server
. Server-CreateObject
. ServerVariables
. Session
. Special-Symbols
. String
. Sub
. Time
CSS
Ecommerce
HTML
InternetProtocol
JAVA
Microsoft
Robots
SearchEngine
SQL
SQLserver
VBscript
XML

SiteMap

3w....学习.教学 > ASP > file » create

3w learning

file >
create

Title:

FileSystemObject.CreateTextFile(filename[,overwrite[,unicode]]) to create a new file (eg .txt .asp .php .jpg .pl ...any file)


Description:

FileSystemObject.CreateTextFile(filename[,overwrite[,unicode]]) true: allow overwrite false: disallow overwrite


Example Code:

Create a file source code 1: <% ' source code : allow overwrite dim fso,newfile set fso=Server.CreateObject("Scripting.FileSystemObject") set newfile=fso.CreateTextFile("c:\mypath\newfile1.txt",true) newfile.WriteLine "text here" newfile.close set newfile=nothing set fso=nothing %> Check a file source code ------------- <% if fso.fileExists ("c:\mypath\newfile1.txt") then end if set fso=nothing %> you may use <% Set AppendText = "(appent a text line after old file)" Set fso = CreateObject("Scripting.FileSystemObject") filename = server.mappath("c:\mypath\newfile1.txt") Set appendfile = fso.OpenTextFile(filename,8,True) appendfile.writeline(AppendText) appendfile.close Set appendfile = Nothing Set fso = Nothing %>


Example Result:



..
...
...

[ 7/27/2008 ]

www learning school add more scripts and tips memo
You are at >>3WS.EZER.COM >> 3WS.EZER.COM/ASP/FILE/CREATE.ASP>>ASP
Helpful link:: SEO web tools :: Live PR | SERP checker
back to top Ezer code adding :: Questions ;email