Skip to content
General IRCX

variables and listboxes

A TG007 community discussion started by Rhys.

Discussion 5 posts
Page 1 of 1
Open
Topic #2108 · 5 published posts · 1,129 views

how can i add a variable like below to a list box, but have 1 name per line and remove the comma?

 

%mirc.adminsonline you, err0r, ozzy, someone,

 

add that into a list box, so it would look like this

 

you

err0r

ozzy

someone

put this in your init of dialog

 

didtok $dname <id> 44 %mirc.adminsonline

You'd have to take out the spaces too, btw. If you do it as you have there it'll come out with a space before their name.

I'm 90% sure that's what happens anyway...

 

on *:DIALOG:dialogname:init:0: {

var %o = 1

while (%o <= $numtok(%mirc.adminsonline,44)) {

did -a dialogname id $gettok(%mirc.adminsonline,%o,44)

inc %o

}

}

 

make sure you change the following

 

dialog name to the name of your dialog

 

id to the id of the box you want to put the var into

 

 

the above code will place them under each other

 

eg

%mirc.adminsonline you,err0r,ozzy,someone

 

would show in box as

 

you

err0r

ozzy

someone

Edited Dec 5, 2004 1:48 AM by OZZY_10â„¢

My code does NOT have bugs. It just develops random features.

Either use what thegatekeeper said or:

 

tokenize 44 %mirc.adminsonline
did -a dname id $*