Sorry, i forgot to attach the file.
Thanks jguinch for the snippnet.
I did this way..
$file = FileOpenDialog("Select your file",@DesktopDir,"Text document (*.txt)|All files (*.*)")
$data = FileRead($File)
$lines = StringSplit($data, @lf)
If IsArray($lines) Then
$linecount = $lines[0]
Else
$linecount = 0
Endif
For $i = 1 to $linecount
$txt = StringStripWS(FileReadLine($file, $i),1)
if StringInStr($txt,'"') then $txt = StringReplace($txt,'"',"")
if StringRegExp($txt, "(?mi)(\N*(?:(http)|(https)|(rtmp)|(rtmps)):\N*)") Then
if StringInStr($txt,"http") Then
$txt = StringMid($txt, StringInStr($txt,"http"))
ElseIf StringInStr($txt,"https") Then
$txt = StringMid($txt, StringInStr($txt,"https"))
ElseIf StringInStr($txt,"rtmp") Then
$txt = StringMid($txt, StringInStr($txt,"rtmp"))
ElseIf StringInStr($txt,"rtmps") Then
$txt = StringMid($txt, StringInStr($txt,"rtmps"))
EndIf
$upscount = $upscount + 1
ConsoleWrite ($txt &@CRLF)
EndIf
If StringinStr($txt, '#EXT') Then
$downscount = $downscount + 1
EndIf
Next
Exit
works just fine. Any comments to make it more efficient are welcome !!
boc.txt