Welcome to the VanDyke Software Forums

Join the discussion today!

Go Back   VanDyke Software Forums > Scripting

Thread Tools Rate Thread Display Modes
Old 06-27-2018, 08:59 AM
Hang Hang is offline
Registered User
Join Date: Jul 2016
Posts: 18
Procomm to SecureCRT

In procomm there are two ways to display text on the terminal. You can do it using transmit and termmsg.

transmit string [RAW]:Sends a character string to the active port. If local echo is on, transmit echoes the string to the Terminal display.

termmsg string | {formatstr arglist} [RAW]:Writes a formatted string to the Terminal window at the current cursor location, updating that location accordingly. termmsg does not process caret ("^") sequences.

The SecureCRT equivalent to Procomm "transmit" is crt.Screen.Send. I was wondering if there is a SecureCRT equivalent for "termmsg"?

The difference between the two is huge. Here is an example of both.

If I use transmit: "^M" is equivalent to pressing 'r'n.

transmit "hello world!^M"
transmit "hello earth!^M"
OUTPUT on terminal: The router OS is expect keyword command hence the bad command prompt from the OS.

*A:# hello world!
Error: Bad command.
*A:# hello earth!
Error: Bad command.
If I use termmsg:
termmsg "hello world! 'r'n"
termmsg "hello earth! 'r'n"
OUTPUT on terminal: you see how it does not provoke the OS to check for a keyword command and it output the messages nicely, no bad command message.
*A:# hello world!
hello earth!
My question is that, is there an equivalent command in SecureCRT that will do what "termmsg" does in Procomm?

Reply With Quote
Old 06-27-2018, 09:30 AM
bgagnon bgagnon is offline
VanDyke Technical Support
Join Date: Oct 2008
Posts: 3,784
Hi Hang,

Thanks for the info. If I understand correctly what you are trying to do, I am not sure it really has to do with the difference between those two functions in Procomm.

To send a line ending in VBScript, use vbcr. In Python, use "\r":

crt.Screen.Send "Hello World" & vbcr

crt.Screen.Send("Hello World\r")

Transmit in Procomm seems to be equivalent to crt.Screen.Send() as you noted.

I believe termmsg is the equivalent of using crt.Screen.Send() with the optional argument shown below.

The above functionality was added in SecureCRT v7.2:

Changes in SecureCRT 7.2 (Beta 1) -- October 8, 2013 (

New features:

  • The script function Screen.Send() can be used to send text to the screen only by using a new optional parameter.
Attached Images
File Type: png SecureCRTHelpTopic_ScreenObject_SendToScreenOnly.png (115.6 KB, 203 views)

VanDyke Software
Technical Support
(505) 332-5730

Last edited by bgagnon; 06-27-2018 at 09:33 AM.
Reply With Quote
Old 06-27-2018, 10:20 AM
Hang Hang is offline
Registered User
Join Date: Jul 2016
Posts: 18
Thanks Brenda!! This is exactly what I was looking for.
Reply With Quote

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

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 11:09 AM.