Option Explicit
Dim sourcefile,ipaddress,objargs
const destfile="tempfile"
Const ForWriting = 2
Dim Text
Dim fso,objNet,ServiceObj
Dim txtStream, txtStreamOut
Set objArgs =
If = 2 Then
sourcefile=objArgs(0)
ipaddress=objargs(1)
Else
"Parameter Error"+ vbcrlf
"USAGE: LogFileName YourIP."
1
End If
Set fso = CreateObject("")
if (sourcefile) then
Set objNet = ( "" )
Set ServiceObj = GetObject("WinNT://" & & "/w3svc")
Set objNet=nothing
6000
Set txtStream = (sourcefile)
Set txtStreamOut = (destfile, ForWriting, True)
Do While Not ()
Text =
if instr(Text,ipaddress)=0 then
Text
end if
Loop
Set txtStream = Nothing
Set txtStreamOut = Nothing
"The log file-- " & sourcefile &" has cleaned your IP!"
Else
"The Log file-- " & sourcefile & " has not found!"
End If
destfile, sourcefile
destfile
Set fso=Nothing
Set ServiceObj = Nothing
Dim sourcefile,ipaddress,objargs
const destfile="tempfile"
Const ForWriting = 2
Dim Text
Dim fso,objNet,ServiceObj
Dim txtStream, txtStreamOut
Set objArgs =
If = 2 Then
sourcefile=objArgs(0)
ipaddress=objargs(1)
Else
"Parameter Error"+ vbcrlf
"USAGE: LogFileName YourIP."
1
End If
Set fso = CreateObject("")
if (sourcefile) then
Set objNet = ( "" )
Set ServiceObj = GetObject("WinNT://" & & "/w3svc")
Set objNet=nothing
6000
Set txtStream = (sourcefile)
Set txtStreamOut = (destfile, ForWriting, True)
Do While Not ()
Text =
if instr(Text,ipaddress)=0 then
Text
end if
Loop
Set txtStream = Nothing
Set txtStreamOut = Nothing
"The log file-- " & sourcefile &" has cleaned your IP!"
Else
"The Log file-- " & sourcefile & " has not found!"
End If
destfile, sourcefile
destfile
Set fso=Nothing
Set ServiceObj = Nothing