View Single Post
  #2  
Old 10-25-2019, 12:56 PM
ashiosee ashiosee is offline
Member
 
Join Date: Oct 2019
Posts: 24
Post

Quote:
Originally Posted by MichelLapointe View Post
Is there a way to quickly view the number of opened sessions?
That is a great question!

Currently SecureCRT does not support that functionality natively.

I have recorded a feature request on your behalf for the ability to display or view the number of opened sessions. Should a future release of SecureCRT include this feature, notification will be posted here. If you prefer direct email notification, send an email to support@vandyke.com with a subject of: "Feature Request - Forum Thread #13951".

In the mean time, there is a way to display this information via a script. Imagine having a button mapped to run the script. When pressed, the number of connected/total tabs would appear in the status bar for a brief moment.
Code:
# $language = "VBScript"
# $interface = "1.0"

nTotalTabs = crt.GetTabCount
nConnected = 0

' Iterate through all of the tabs, finding out how many are connected:
For nIndex = 1 To nTotalTabs
    Set objCurTab = crt.GetTab(nIndex)
    If objCurTab.Session.Connected Then
        nConnected = nConnected + 1
    End If
Next

' Compose a report of the number of connected/total tabs:
strTabReport = nConnected & "/" & nTotalTabs & " connected tabs."
' Display the data to SecureCRT's status bar
crt.GetScriptTab().Session.SetStatusText strTabReport
' Wait a couple of seconds
crt.Sleep(2000)
' Clear the status bar
crt.GetScriptTab().Session.SetStatusText ""
Does this script workaround seem like it might meet your needs in the interim?
__________________
--Allen

VanDyke Software
Technical Support
support@vandyke.com
(505) 332-5730
Reply With Quote