Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Nov 9th, 2005, 11:37 AM   #1
paulchwd
Hobbyist Programmer
 
paulchwd's Avatar
 
Join Date: Mar 2005
Posts: 139
Rep Power: 4 paulchwd is on a distinguished road
Exclamation Flat files help

Hello all,

I haven't worked with flat files in a while ande cant get it to append data

i have this code thus far and it not appending the data

dim fs,fname, pathF

const forAppending = 8

pathf=server.mappath("err.txt")

set fs=Server.CreateObject("Scripting.FileSystemObject")

set fname=fs.CreateTextFile(pathf, forAppending, true)

fname.WriteLine("Hello World!")

fname.Close

set fname=nothing

set fs=nothing

thanks for your help
paulchwd is offline   Reply With Quote
Old Apr 18th, 2006, 11:21 PM   #2
BaldEagle
Newbie
 
BaldEagle's Avatar
 
Join Date: Apr 2005
Location: Lisbon, CT
Posts: 9
Rep Power: 0 BaldEagle is on a distinguished road
change this
set fname=fs.CreateTextFile(pathf, forAppending, true)

to this
set fname=fs.OpenTextFile(pathf, forAppending, true)

Create does not use the append parameter. Open does.

BaldEagle
__________________
If you can't be kind, at least have the decency to be vague.

You may be only one person in the world, but you may also be the world to one person.

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names, and all are different colors, but they all manage to live comfortably in the same box.
BaldEagle is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 12:44 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC