View Single Post
Old 05-15-2013, 10:41 AM
gunslingor gunslingor is offline
Registered User
Join Date: May 2013
Posts: 27
Chapter 3: Connecting to Remote Machines

I learned a lot from this chapter, but the one method I want to use isn't listed there, so I'm wondering if it (or something like it) is even possible.

Here's my slowly evolving simple first script:
Sub Main()
	'Run "C:\Program Files\VanDyke Software\SecureCRT\SecureCRT.exe"
	crt.Session.Connect "/Serial COM6 /BAUD 9600"
	crt.Screen.Send chr(13)
	crt.Screen.WaitForString "username:"
	crt.screen.send  "Myusername"
	crt.screen.send chr(13)
End sub
so I'd like the first thing to happen to be a message box or similar asking if the user wants serial or ssh connection... assuming serial, the above connect statement would run, assuming SSH what I want to happen is for the connect dialog to pop up with all my predefined sessions... when a user selects the session they want execution is passed back to the script which then runs a similar connect statement for SSH.

Is there underlined text above even possible? Is there a way to emulate it if not? I might be making this more complicated than it needs to be... perhaps I should just connect manually, then run the script that is intended to only capture and parse data using, primilary, show commands that will later be imported into a DB.
Reply With Quote