Solved

Telnet in Visual Basic

Posted on 1998-09-07
2
1,636 Views
Last Modified: 2013-11-25
I need to know how to connect to a telnet site in VB.

I will need to be able to see the output of it, and be able to manipulate, and also input info to the telnet server.... basiclly I'm making an enhansed telnet client just for a specific server.

I need to be able to insert the IP address and port number of it.

I use VB1 and VB5, so whichever one you use, you can tell me about (although I don't think VB1 has the capabilities)

Thanks!

If it requires a special file (like an OCX), please tell me where I can get it then.
0
Comment
Question by:eversoslightly
2 Comments
 
LVL 1

Accepted Solution

by:
kacklehorn earned 20 total points
Comment Utility
Put a msWinsock control..(found in VB5) on a form with a large textbox(text1) and three small textboxes IPaddress(text2) port#(text3) Commands(text4). Two command buttons:

Option Explicit

Private Sub Command1_Click()
    Winsock1.Connect Text2.Text, Text3.Text
End Sub

Private Sub Command2_Click()
    Winsock1.SendData Text4.Text
End Sub

Private Sub Form_Load()

End Sub

Private Sub Winsock1_DataArrival(ByVal bytesTotal As Long)
Dim buffer As String
Winsock1.GetData buffer, vbString
Text1.Text = buffer
End Sub


Thats it..Enjoy
0
 
LVL 1

Author Comment

by:eversoslightly
Comment Utility
Thanks!  Worked like a charm :)

Ever-So
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

772 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now