mIRC Homepage
Posted By: westor /comlist command - 03/06/14 06:44 PM
Hello,

I wanna request to add this command into the mIRC core, i know that there are many ways to script this command but it will be more easy and logic if the mIRC had this command as far has /socklist and /flist for, i think in my opinion this is not something very important but it can't be missing it makes the mIRC more poor into the scripting code, also helping users that has not any idea about script that if they using any script to know which COM is in use into their pc, /socklist command it's very helpfull when trying to build an code with sockets why not make /comlist to help the users with it.

- Thanks!
Posted By: FroggieDaFrog Re: /comlist command - 03/06/14 07:05 PM
I've had need for this in the past.


My scripted version:
Code:
alias comlist {
  var %x = 1
  while ($com(%x)) {
    if (%x == 1) {
      echo $color(info) -a * Open COMs:
    }
    echo -a $com(%x)
    inc %x
  }
  if (%x == 1) {
    echo $color(info) -a * No open COMs
  }
}
Posted By: TRT Re: /comlist command - 04/06/14 11:25 AM
You should always check $com != null.
(Even though it's clearly not best practice, a script may still use ^0+$ as a valid name)
© mIRC Discussion Forums