mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Dec 2002
Posts: 295
S
Fjord artisan
OP Offline
Fjord artisan
S
Joined: Dec 2002
Posts: 295
Hi all, i`m trying to get mIRC to display a whole text file in a list box, suppose i have a text file (plain formatted)
and it has 10 lines.

---------------------------------
Shadowdemon
Line2
Line3
Line4
...and so on
Line10
---------------------------------

Now i want to display all 10 lines in a List box, not just 1 or randomly but in a sequence, ie my nick at the top and Line10 (as in the example) at the bottom



This is part of the code i`m having problems with
Code:
  on 1:dialog:clanshow:init:0: {
  did -a clanshow [color:red]9[/color] $read(clanrules.txt)
  did -a clanshow [color:blue]10[/color] $read(clanmembers.txt)
}


Using $read outputs only 1 random line into my list box at id number 9 and 10 respectivly, i use two very different text files, and different names and are of differnt sizes.

I just been reading the help file on the $read command, and other $ type related stuff, but still cant get it worked out

Any help would be helpful grin

What i want to do is to be able to give this script to my clan members to display the rules and new members, all i have to do is update the text file and DCC send it or email the new memebrs list to my members and overwrite the existing clanmembers.txt file without getting them to edit or muck about with the script., esp if they dont know what they doing.

ShadowDemon
mIRC V6.03


Never argue with an idiot...they'll drag you down to their level and beat you up with experience
Joined: Jan 2003
Posts: 2,523
Q
Hoopy frood
Offline
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,523
/help /loadbuf
Code:
on *:dialog:clanshow:init:0:{
  loadbuf -o $dname 9 clanrules.txt
  loadbuf -o $dname 10 clanmembers.txt
}
You can also do this with /filter.


/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com
Joined: Dec 2002
Posts: 295
S
Fjord artisan
OP Offline
Fjord artisan
S
Joined: Dec 2002
Posts: 295
Thanks qwerty, it works, i didnt know about /loadbuf or /filter, i`ll look them up now in the help file.


ShadowDemon


Never argue with an idiot...they'll drag you down to their level and beat you up with experience

Link Copied to Clipboard