You missed a bit from my 1st post in this thread:
Quote:
Of course this will affect any usage of the /names command, so you could set a variable in your 'mycommand' which you test for in the above on raw events, then reset that variable at the end of your command, to allow for normal usage.


If I remeber correctly your alias is called 'MyCommand'. In there set a variable to 1 and at the end of that alias set it to 0 (zero). Into that section On Raw 353

You put a test of that variable and only execute the code I wrote if it is true (i.e. is equal to 1).

Change things to this as an example
Code:
On raw 001 :*: {
   Set %LineCounter 1
}

On raw 353:*: {
   if (%MyTrigger) {
      if (%LineCounter <= 3) { //echo -s $1- }
      inc %LineCounter
      haltdef
   }
}

; reset counter to 1 ready for next channel
On raw 366:*: { 
   if (%MyTrigger) {
      %LineCounter = 1
      haltdef
   }
}


Now your My command will set %MyTrigger to 1, and any name commands that the alias sends will only get the 1st 3 lines displayed, and when all channels have been processed, you alias sets %MyTrigger to 0. If you then type /names #<whatever> the 'if %MyTrigger' will be false and those lines about %linecounter and haltdef are not executed.

Last edited by Erasimus; 09/04/19 06:39 PM.