Solved

to create  telnet object and open connection

Posted on 2000-02-25
3
178 Views
Last Modified: 2012-06-27
Is it possible to create telnet from VB using late binding and
1. open  connection to remote server, 2  pass a user id and password programmatically  and 3. make telnet  visible
0
Comment
Question by:mativare
  • 2
3 Comments
 
LVL 14

Accepted Solution

by:
mcrider earned 100 total points
ID: 2559039
Here's an example using  a command1 button... Add this to a form:


Sub Sleep(Interval As Long)
    Dim lTimer As Long
    lTimer = Timer + Interval
    Do While Timer < lTimer
        DoEvents
    Loop
End Sub
Private Sub Command1_Click()
    Dim lReturn As Variant
    lReturn = Shell("Telnet hostname", vbNormalFocus) 'REPLACE hostname WITH NAME OF HOST
    AppActivate lReturn
    Sleep 1
    SendKeys "mcrider{ENTER}" 'SEND USERID
    Sleep 1
    SendKeys "noneofyourbusiness{ENTER}" 'SEND PASSWORD
End Sub


Hope this helps!


Cheers!
0
 
LVL 1

Author Comment

by:mativare
ID: 2559778
Impressive!
0
 
LVL 14

Expert Comment

by:mcrider
ID: 2560429
Thanks for the points! Glad I could help!


Cheers!
0

Featured Post

ScreenConnect 6.0 Free Trial

At ScreenConnect, partner feedback doesn't fall on deaf ears. We collected partner suggestions off of their virtual wish list and transformed them into one game-changing release: ScreenConnect 6.0. Explore all of the extras and enhancements for yourself!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

773 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question