If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > ASP > How to delete line from a file?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-26-03, 03:52
liorlank liorlank is offline
Registered User
 
Join Date: Nov 2003
Posts: 22
How to delete line from a file?

I need the code in ASP that get a file name (path)
<%
path="test.txt"
%>
search the line in the file that begin with the word "word1"
and delete this line from the file.

How to do it???
Reply With Quote
  #2 (permalink)  
Old 11-26-03, 14:45
fhunth fhunth is offline
Registered User
 
Join Date: Oct 2002
Location: Argentina
Posts: 72
Re: How to delete line from a file?

You can use the object "Scripting.FileSystemObject"

With this object you can open the file , read a line , etc



Quote:
Originally posted by liorlank
I need the code in ASP that get a file name (path)
<%
path="test.txt"
%>
search the line in the file that begin with the word "word1"
and delete this line from the file.

How to do it???
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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
Trackbacks are On
Pingbacks are On
Refbacks are On