mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Nov 2004
Posts: 84
GogetaX Offline OP
Babel fish
OP Offline
Babel fish
Joined: Nov 2004
Posts: 84
how to use with List Box?
to read file, and past to the list
how?


by the time you finish reading this, you realize you have wasted 5 secundes of your life!
Joined: Sep 2004
Posts: 237
Fjord artisan
Offline
Fjord artisan
Joined: Sep 2004
Posts: 237
err...... maybe its just me , but could you be more specific?

Joined: Aug 2003
Posts: 1,831
I
Hoopy frood
Offline
Hoopy frood
I
Joined: Aug 2003
Posts: 1,831
Many ways, heres two

  • loadbuf -o file.txt dialog did
  • filter -fo file.txt dialog did [*wildtext*]

Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Another way which I use is by getting it to write to 2 files, one the nickname, and one telling it to /did -a into the dialog then playing it to status with 0 ms delay.

Code:
menu channel {
  $iif($dialog(friends),$style(3)) Friends List: { 
    dialog -dmo friends friends
  }
}

Dialog friends {
  Title "friends List"
  Size -1 -1 124 120
  Option dbu
  Text "Gogetax Friends List.",1, 4 2 100 32
  List 5, 2 39 120 66, sort
  Box "",6, 2 36 120 58
  Button "&Add",7, 2 97 27 10
  Button "&Del",8, 95 97 27 10
  Button "&Ok",9, 49 97 27 10, ok
}

on 1:dialog:friends:init:*: {
  write FL.Users1.txt  
  play -cs FL.Users1.txt 0
  did -b friends 8
}

on 1:dialog:friends:sclick:5: { 
  set %FL.sel $did(5,$did(5).sel)
  did -e friends 8 
}

on 1:dialog:friends:sclick:7: { 
  set %FL.add $$?="Enter nickname to add:" 
  write " $+ FL.Users1.txt $+ " did -a friends 5 %FL.add
  did -a friends 5 %FL.add 
  write " $+ FL.Users2.txt $+ " %FL.add
  .friends %FL.add 
  .Echo -a Added %FL.add to friends list!
}

on 1:dialog:friends:sclick:8: { 
  write -dw $+ "* $+ %FL.sel $+ *" FL.Users1.txt 
  write -dw $+ "* $+ %FL.sel $+ *" FL.Users2.txt 
  did -d friends 5 $did(friends,5).sel 
  did -b friends 8
  .friends -r %FL.sel
  .Echo -a *** Removed %FL.sel from friends list!
} 

on 1:dialog:friends:sclick:9: { 
  dialog -x friends friends 
}

on 1:dialog:friends:close:*: {
  unset %FL.*
}


Link Copied to Clipboard