"...Remember being a youngster, mom or dad telling you "close the door"? Well the same applies to HTML ...."

Go Back   Webmaster Forums > Code Forum > HTML Forum

Reply
 
Thread Tools Rate this Webmaster Discussion
Old 11-08-2009, 10:01 AM   #1
vexixx
New Member
 
Join Date: Nov 2009
Webmaster Discussions: 2
Rep Power: 5
vexixx is on a distinguished road
Question VBScript/Html Help

Hey guys this is my first post. I've been getting alot of information off the site, but I'm trying to put something together and having trouble. You see it works, but it works to fast. What the code is doing is telneting into a router and instantly dropping all the text and it messes up.
<HTML>
<script language="VBScript">
<!--

Sub Validate
Dim oshell
Set oshell = createobject("Wscript.Shell")
oshell.run"telnet.exe"
oshell.sendkeys"open 10.210.226.229"+("{Enter}")
oshell.sendkeys"admin"+("{Enter}")
oshell.sendkeys"admin1234$"+("{Enter}")
oshell.sendkeys"telnet 10.210.91.9 /source f0/1"+("{Enter}")
oshell.sendkeys"root"+("{Enter}")
oshell.sendkeys"ttelnet"+("{Enter}")
oshell.sendkeys" "+("{Enter}")

Dim TheForm
Set TheForm = Document.forms("ValidForm")

If TheForm.show_ber.checked = true Then
oshell.sendkeys"show_ber"+("{Enter}")
End If

If TheForm.rb.checked = true Then
oshell.sendkeys"rb"+("{Enter}")
End If

If TheForm.tc.checked = true Then
oshell.sendkeys"tc"+("{Enter}")
End If


End Sub

-->
</script>
</head>

<body>
<h3>78730</h3>
<hr>
<form id="ValidForm" action=""
onsubmit="Validate(); return false;" language="jscript">

Show_ber:
<input type=checkbox name="show_ber" size="12"><BR>
RB
<input type=checkbox name="rb" size="12"><BR>
TC
<input type=checkbox name="tc" size="12"><BR>
<input name="Submit" type="Submit" value="Submit">

</form>
</BODY>
</HTML>

I need it to log in with telnet and then peform the selected commands, I tried WScript.Sleep but it just stops the script from running whereever its at. Any have anything for me please? Thank you very much



Last edited by vexixx; 11-08-2009 at 11:01 AM.
vexixx is offline   Reply With Quote
Old 11-16-2009, 01:21 AM   #2
vexixx
New Member
 
Join Date: Nov 2009
Webmaster Discussions: 2
Rep Power: 5
vexixx is on a distinguished road
Re: VBScript/Html Help

I've tried some other commands .waits and some others just "hoping" lol still can't make it pause.
vexixx is offline   Reply With Quote
Reply

Bookmarks

Tags
vbscript or html

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Webmaster Discussions
Thread Webmaster Discussion Starter Forum Replies Last Post
Vbscript/html Checkbox punex HTML Forum 0 10-23-2008 11:18 PM
Variable problems in HTML / Vbscript craigpollard HTML Forum 0 08-19-2007 10:09 PM
VBscript difficulty dsnorm Website Scripts Forum 1 09-15-2006 04:33 PM
HTML/VBSCRIPT checkbox help...please Pbalais Website Scripts Forum 4 03-13-2006 03:20 PM
HTML/VBSCRIPT checkbox help TBird2424 Website Scripts Forum 7 03-16-2004 09:38 AM


All times are GMT -5. The time now is 09:12 PM.


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.