mIRC

This is a short mirc script to advance to the next highlighted channel, first by highlight, then by general activity. Put it in your Aliases.

F2 {

nexthl

nextmsg

}

nexthl {

var %serv = 1

while ($scon(%serv)) {

scon %serv

var %chan = 1

while ($window(*, %chan).wid != $null) {

if ($window(*, %chan).sbcolor == highlight) {

var %x = %chan - 1

if ((%x <= $chan(0)) && (%x > 0)) {

window -a $chan(%x)

halt

}

}

inc %chan

}

inc %serv

}

}

nextmsg {

var %serv = 1

while ($scon(%serv)) {

scon %serv

var %chan = 1

while ($window(*, %chan).wid != $null) {

if ($window(*, %chan).sbcolor == message) {

var %x = %chan - 1

if ((%x <= $chan(0)) && (%x > 0)) {

window -a $chan(%x)

halt

}

}

inc %chan

}

inc %serv

}

}