mIRC Home    About    Download    Register    News    Help

Print Thread
#71734 17/02/04 07:35 PM
Joined: Sep 2003
Posts: 156
B
bleach Offline OP
Vogon poet
OP Offline
Vogon poet
B
Joined: Sep 2003
Posts: 156
I heard that files can be read by using F.H.S. and tried to write code to read one but can't find a way to read.. so I need an example.. can anyone help me..

#71735 17/02/04 09:52 PM
Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
Code:
alias gfilter {
if !$window($1) { window $1 }
.fopen test $2-
while !$feof { echo $1 $fread(test) }
.fclose test
}

/gfilter <@window> <filepath>
this is just an example
.fopen test $2- - opens a file to use, $2- is the filepath.
while !$feof - checks the end of file hasn't been reached.
$fread(test) - reads the line.
.fclose test - closes the file.


New username: hixxy
#71736 18/02/04 09:08 AM
Joined: Sep 2003
Posts: 156
B
bleach Offline OP
Vogon poet
OP Offline
Vogon poet
B
Joined: Sep 2003
Posts: 156
thanks

#71737 18/02/04 02:50 PM
Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
np smile


New username: hixxy

Link Copied to Clipboard