Dim fso, f , Readline_file,wordcount,i
i=0
Set fso = Createobject(“Scripting.FileSystemObject”)
‘Set Myfile = fso.OpenTextFile (“g:\new.txt”, ForWriting , True)
‘Set f = fso.CreateTextFile (“g:\new2.txt”, True)
‘f.writeline “world hello”
‘f.writeline “Google 05121974”
Set f = fso.OpenTextFile(“g:\new2.txt”)
do until f.AtEndOfStream = true
Readline_file = f.readline
wordcount = split(Readline_file,” “)
For each i in wordcount
If (i = fine) Then
msgbox “sucess”
End If
‘msgbox Readline_file
Next
Loop
‘Readline_file = f.read (5)’ (“g:\new1.txt”, )
‘Set f = fso.OpenAsTextStream(“g:\new1.txt”)
‘f.Writeline “Enter into the new world”
f.Close
Discuss This Question: