Welcome to the VanDyke Software Forums

Join the discussion today!

Go Back   VanDyke Software Forums > General

Thread Tools Display Modes
Old 04-27-2012, 01:18 AM
miteethor miteethor is offline
Registered User
Join Date: Apr 2012
Posts: 15
Can a Button be toggled to send to all tabs?

I love the chat bar with the send to all tabs function. It's awesome.

I love buttons.

Can buttons be setup to act like the chat bar? Maybe a right-click function on the bar to allow send to all tabs on the button? I have to check a lot of routers when doing maintenance and the commands are extremely repetitive - I could do a lot of checking with just a couple of clicks across a lot of devices at the same time.

Conversely, if that isn't available, is there a way to trigger this via a script? Either something that populates the chat bar or that could send a text command to all tabs?

Reply With Quote
Old 04-27-2012, 08:32 AM
rtb rtb is offline
VanDyke Technical Support
Join Date: Aug 2008
Posts: 4,306
Hi miteethor,

Thanks for the question. Currently, it is not possible to use a button to send a command to all tabs. I have created a feature request to add this behavior in our SecureCRT enhancement database.

I also created a feature request to add a Chat Window object to the SecureCRT scripting API.

Should a future release of SecureCRT have either feature added, we will post to this forum thread.

If you would like to be notified directly, please complete and submit the form at the following location:
Submit Feature Request
In the meantime, it is possible to send a command to all open tabs using a script.

There is an example written in VBScript that illustrates iterating over all open tabs in the forum thread at the following location:
Rather than obtaining information about the tab and popping a message box, you could interact with each tab as you iterate over the tabs by sending commands and ensuring that they are completed.

If you are not familiar with the SecureCRT scripting API, you can find information on sending data to and waiting for data from remote machine in chapters 5 and 4 respectively in the script manual at the following location:
It is also important to note that when interacting with a remote machine, you should use the Synchronous property. The importance of using this property is covered on page 39 of the scripting manual.

Is this information helpful?

VanDyke Software
Technical Support
Reply With Quote
Old 04-30-2012, 09:49 AM
miteethor miteethor is offline
Registered User
Join Date: Apr 2012
Posts: 15
Actually, you have been very helpful. I have thrown together a quick and dirty solution to my problem based on some of the examples and it seems to be working great so far. All you have to do is call this file and put your command in "quotes" in the arguments section of the button, and it will send to all connected tabs.

To use this code, save in a .vbs file.

Create a new button:
Function: Run Script
Run Script: path to the .vbs file
Label: put what you want the button to read, such as sh run all
Arguments: "sh run" or something similar in quotes
Click the button!

strCmd = crt.Arguments(0)
crt.Screen.Synchronous = True
For nIndex = 1 To crt.GetTabCount
    Set objCurrentTab = crt.GetTab(nIndex)
	bConnected = objCurrentTab.Session.Connected
	if bConnected then
			objCurrentTab.Screen.Send strCmd & vbcr
	End If

Reply With Quote
Old 09-18-2012, 04:01 PM
Maureen's Avatar
Maureen Maureen is offline
VanDyke Product Director
Join Date: Feb 2004
Location: Albuquerque, NM
Posts: 1,597
The ability to send a button action to all tabbed or tiled sessions has been added to a pre-beta version of SecureCRT. If you would be interested in trying it, please send e-mail to me at Maureen.Jett@vandyke.com.

Reply With Quote

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT -6. The time now is 01:00 PM.