The Active Array

$active($id).  The $active($id) is the active window for the connection with id number. So if you want to get the active window in savIRC (the window you see), this will be the active window of the active connection; but the active connection is in the me(id) variable so you can get the active window of the program like this:

set w $active($me(id))

So you can use a savIRC function with this variable to get the active channel.

Example 2.1. 

GetChannel $active($me(id)) $me(id)