Welcome to Dream.In.Code
Become an Expert!

Join 149,595 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 1,869 people online right now. Registration is fast and FREE... Join Now!




asp file writing

 
Reply to this topicStart new topic

asp file writing, What's wrong with this code?

brightmessenger
17 Oct, 2007 - 05:46 AM
Post #1

New D.I.C Head
*

Joined: 15 Sep, 2007
Posts: 3


My Contributions
I'm new to web programming. I've followed an example in a book...but can't get this to work for me. This asp file is called by a form in an html file. The data sent to this file will print out with 'response.srite'...but, I can't save the file to the server.

<%

option explicit


dim FSO
dim objStream
dim strText
dim strComment

const TristateFalse = 0


set FSO=createobject("Scripting.filesystemobject")

strText = request.form("title") & ".txt"

strComment = request.form("comment")


Set objStream = FSO.CreateTextFile(strText , True, TristateFalse)

With objStream

.WriteLine strComment
.close

End With


set FSO=nothing
set objStream=nothing
set strText=nothing
set strComment=nothing




%>
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 1/7/09 11:23PM

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter

Live Help!

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month