Solved

Telnet in VB6 code

Posted on 2000-02-15
13
591 Views
Last Modified: 2008-03-10
I want to build a application,
and want to telnet to
Cisco Router and Switch by VB6,
and get some message from
Router and Switch.

Can anybody give me some suggestion or
sample code?
0
Comment
Question by:hxb
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 7
  • 6
13 Comments
 
LVL 7

Accepted Solution

by:
kamall earned 150 total points
ID: 2525388
I have a ready sample project for telnet. The project contains many forms, controls, and menus. So, it will be difficult for you to make it to work if I post it here.
Comment me your e-mail address so I can send it to you.
Regards.
0
 

Author Comment

by:hxb
ID: 2525453
huangxb@163.net

Thanks
0
 
LVL 7

Expert Comment

by:kamall
ID: 2525468
In your mailbox!
You are welcome.
Regards.
0
Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

 

Author Comment

by:hxb
ID: 2525853
mail not found yet ,
Please CC to huangxb@usa.net
0
 
LVL 7

Expert Comment

by:kamall
ID: 2529644
Forwarded to the new e-mail.
Regards.
0
 
LVL 7

Expert Comment

by:kamall
ID: 2529646
BTW, just this moment, I found the following reply from mail server:

   ----- The following addresses had transient non-fatal errors -----
<huangxb@163.net>

   ----- Transcript of session follows -----
<huangxb@163.net>... Deferred: Connection timed out with mx4.163.net.
Warning: message still undelivered after 8 hours
Will keep trying until message is 5 days old
0
 

Author Comment

by:hxb
ID: 2530309
Adjusted points to 150
0
 

Author Comment

by:hxb
ID: 2530310
Good code.

Questions
  When I try the sample, and
open to the Router, it will
display:

Username:
Username:^@
Username:VT100^@
Password:
%Access Denied

I think if it is correct,
it will only display
"Username:" and I can input the
username.
I think the VB has send some
Chars or chr(13) to Router.

Please give me some suggestion.
0
 
LVL 7

Expert Comment

by:kamall
ID: 2539118
I really can not figure out what goes wrong. The code works very nice for me!
You can easily step througt the code with F8 to see if it sends something after getting the Username string.
Hope that helps.
0
 

Author Comment

by:hxb
ID: 2540837
Thank
0
 
LVL 7

Expert Comment

by:kamall
ID: 2540933
You are welcome hxb.
Did you figured out the problem?
Regards.
0
 

Author Comment

by:hxb
ID: 2541535

I REM the code
'        Case TERMTYPE
in IAC1() and IAC2()
and the router will display:
Username:      'Line 1
Username:      'Line 2

and then I can login.
I think the VB send some code to
the router after it receive
the "Username:".

How to let it only display one
"Username:"?
If I do not send
the TERMTYPE to the router,
is it OK?



0
 
LVL 7

Expert Comment

by:kamall
ID: 2552951
hxb,
why don't give it a try and see?
I think that (usually), you should send the terminal type to the remote host and get the response, but I'm not really sure.
Regards.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
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…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
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…
Suggested Courses
Course of the Month10 days, 1 hour left to enroll

624 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