mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Dec 2002
Posts: 271
N
Fjord artisan
OP Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 271
hey,

i cant seem to remember how to rad from an ini file, looking for data matching "data", example:

1=some data here
2=other data here

i was sure i used something like:

$readini(file,w,section,*other data here*).item

would return 2

or are my memories mixed up? and maybe i wrote an alias that looped through all items in that section and compared the data to yours and return item upon match? i was sure there was a built in for that.....

thanks

Joined: Dec 2002
Posts: 271
N
Fjord artisan
OP Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 271
kinda like this that i just made up


alias -l finditem {
var -s %cur = 1, %tot = $ini($1,$2,0)
while (%cur <= %tot) {
var -s %data = $readini($1,$2,%cur)
if (%data == $3-) { return $ini($1,$2,%cur) }
inc %cur
}
return
}


but i was sure there was a built in, anyone know?


Link Copied to Clipboard