Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21839

[RESOLVED] Edit a text file

$
0
0
I am trying to edit a textfile:
Open the textfile, find the item I need and then replace the new item(line) to the file.
Until now I have got this:

Code:

Open "C:\TextFile.txt" For Input As #1
  While Not EOF(1)
    Line Input #1, strData
    'Found the line to replace 
Wend
Close #1

I hope someone can help me,
Regards, Kars

Viewing all articles
Browse latest Browse all 21839

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>