mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Dec 2002
Posts: 79
F
Fantas Offline OP
Babel fish
OP Offline
Babel fish
F
Joined: Dec 2002
Posts: 79
i've tried multsel and extcel and they will highlight them but what i want to do is for it to send a message to all selected
on *:dialog:user.list:sclick:4: {
msg $did(2).seltext $$?="message?*"*
}

thanks

Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Code:
on *:dialog:user.list:sclick:4: { 
  var %x = 1
  while (%x <= $did($dname,2,0).sel) { 
    msg $did($dname,2,%x).seltext $$?="message"
    inc %x
  }
}

Joined: Dec 2002
Posts: 79
F
Fantas Offline OP
Babel fish
OP Offline
Babel fish
F
Joined: Dec 2002
Posts: 79
i'm afraid all that does is message same nick several times

Joined: Aug 2005
Posts: 1,052
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
Originally Posted By: SladeKraven
Code:
on *:dialog:user.list:sclick:4: { 
  var %x = 1
  while (%x <= $did($dname,2).lines) { 
    msg $did($dname,2,%x).text $$?="message"
    inc %x
  }
}


Here you go made changes into the quote His method would require you to have a multi selection selected in your editbox which would require your dialog input to have extsel added ex:.

list 2, xyhw, size extsel

see the extsel? this will allow you to click or a nick press shift and select the nick at the bottom to select all nicks, then his script would work

else without selecting anyone, the re-write I did would message all users.


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
Joined: Dec 2002
Posts: 79
F
Fantas Offline OP
Babel fish
OP Offline
Babel fish
F
Joined: Dec 2002
Posts: 79
that's closer but i didn't want to message all nicks just one's highlighted

Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Code:
on *:dialog:user.list:sclick:4: { 
  var %x = 1
  while (%x <= $did(2,0).seltext) { 
    msg $did(2,%x).seltext $$?="message"
    inc %x
  }
}

Last edited by RusselB; 12/09/07 11:21 PM.
Joined: Aug 2005
Posts: 1,052
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
Originally Posted By: Fantas
that's closer but i didn't want to message all nicks just one's highlighted


Ya i noted that it was gonna do that lol :P


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
Joined: Dec 2002
Posts: 79
F
Fantas Offline OP
Babel fish
OP Offline
Babel fish
F
Joined: Dec 2002
Posts: 79
none of these actually do what i want thanks anyways

Last edited by Fantas; 13/09/07 02:41 PM.
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Code:
dialog user.list {
  size -1 -1 110 110
  option dbu
  list  2, 5 5 100 90, multsel extsel
  button "Send Message",4, 40 95 40 10
}

On *:Dialog:user.list:init:*: {
  didtok $dname 2 32 Adam Bob Chris Dave Evan Fred Gary Henry
}

On *:Dialog:user.list:sclick:4: {
  if ($did($dname,2,0).sel) {
    var %x = 1, %msg = $$?="message?"
    while (%x <= $did($dname,2,0).sel) { 
      msg $did($dname,2,$did($dname,2,%x).sel) %msg
      inc %x
    }
  }
}


I've added a dialog to show you it works. Just open up the dialog and select some nicks and then send the message.

Joined: Jun 2006
Posts: 508
D
Fjord artisan
Offline
Fjord artisan
D
Joined: Jun 2006
Posts: 508
Code:
on *:dialog:user.list:sclick:4: { 
  var %i = 1,%a = $iif($did(2,0).sel,$$?="message")
  while $did(2,%i).sel { 
    msg $did(2,$v1) %a
    inc %i
  }
}

Joined: Dec 2002
Posts: 79
F
Fantas Offline OP
Babel fish
OP Offline
Babel fish
F
Joined: Dec 2002
Posts: 79
those last 2 work great. Thanks Guys


Link Copied to Clipboard