|
#1
|
|||
|
|||
Simple Script Example
Hi, I'm looking to do a telnet script that when runs it prompts you for a IP address then port number. Then when entered it automatically runs a telnet command and displays it on the screen.
I don't mind if the port is hardcoded into the script either. Any help would be appreciated. Thanks Tony |
#2
|
|||
|
|||
Hi Tony,
Do you intend to use VBScript in your scripting efforts? If so, please review the VBScript manual on our website here. Information on SecureCRT specific methods, properties and objects are found in the Scripting / Script Objects Reference topic in SecureCRT's Help file. For example, you can prompt a user for input using crt.Dialog.Prompt: Syntax crt.Dialog.Prompt(message [, title [, default [, isPassword ]]])You would then need to connect to the host, which I believe was illustrated for you in another post. The Send() method, available to the Screen object, is how you can run a command: crt.Screen.Send "MyCommand" & vbcr
__________________
Thanks, --Brenda VanDyke Software Technical Support support@vandyke.com (505) 332-5730 |
![]() |
Tags |
ipaddress , script , telnet |
Thread Tools | |
Display Modes | Rate This Thread |
|
|