mIRC Homepage
Posted By: ThE_mASk /clearall - 14/02/03 04:39 PM
how can I make the command /clearall to clear all windows exept 1 for example @Window
??
Posted By: gerdigos Re: /clearall - 14/02/03 05:44 PM
I'm not sure, but i don't think you can do that with /clearall.
I might come up with some code for you...
Bye
Posted By: gerdigos Re: /clearall - 14/02/03 06:12 PM
Well here I am again. These while loops might help you out a bit /clearing...

var %x, %y, %z, %a
;/clearing all channels...
set %x 1
while ($chan(%x)) {
set %y $ifmatch
clear %y }
inc %x
;/clearing all queries...
set %x 1
while ($query(%x)) {
set %z $ifmatch
clear %z }
inc %x


Hope i helped you out a bit. smile
Posted By: ThE_mASk Re: /clearall - 15/02/03 12:30 PM
Well I tried the script and it got into the loop and it didn't went out confused and I had to use Alt+Ctrl+Del to stop the script...
Posted By: Hammer Re: /clearall - 15/02/03 05:52 PM
Put your inc %x INSIDE the loop, not outside.
Posted By: Online Re: /clearall - 15/02/03 06:19 PM
Using $window(*,N) only one loop is needed to go through all of them (thanks qwerty- for pointing that out).
Code:

var %i = 1
while $window(*,%i) {
  if $ifmatch != @Window { clear $+(",$ifmatch,") }
  inc %i
}

This one "clears" any open window, but that doesn't affect DCC send, URL list or other special ones.
© mIRC Discussion Forums