Photo Gallery
Member List
Search
Calendars
FAQ
Ticket List
Log Out
Forums
Register
Login
My Profile
Inbox
Address Book
My Subscription
My Forums
ssh @ doesnt read
Logged in as: Guest
arrSession:exec spGetSession 2,2,60134
Active Users: There are
0
members and
0
guests.
Users viewing this topic: none
Printable Version
All Forums
>>
[Scripting]
>>
WSH & Client Side VBScript
>> ssh @ doesnt read
Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page:
[1]
Login
Message
<< Older Topic
Newer Topic >>
ssh @ doesnt read -
5/12/2008 11:06:11 PM
zerocool22
Posts: 2
Score: 0
Joined: 5/12/2008
Status:
offline
Hey i have made the following script:
WshShell.SendKeys "ssh user@localhost{ENTER}"
But when he runs this i get:
userlocalhost
He doesnt read the @sign how can i fix this?
Post #: 1
RE: ssh @ doesnt read -
5/12/2008 11:24:58 PM
ehvbs
Posts: 2106
Score: 50
Joined: 6/22/2005
From: Germany
Status:
offline
Hi zerocool22,
I have no problems with .SendkKey "...@..." (wsh 5.6, W2K), so I'm not sure about the
cause of your difficulty. But the 'official' way to escape special chars in .SendKeys parameters
is to put them into {}; so try:
WshShell.SendKeys "ssh user{@}localhost{ENTER}"
Good luck!
ehvbs
(in reply to
zerocool22
)
Post #: 2
RE: ssh @ doesnt read -
5/12/2008 11:30:28 PM
zerocool22
Posts: 2
Score: 0
Joined: 5/12/2008
Status:
offline
hey still no go, but maybe something else is wrong so here is the full script: Could be all bad, i try to login with ssh on my server true putty.
set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run "putty.exe 81.246.70.155 -l root -pw pasword"
WScript.Sleep 2000
WshShell.AppActivate "81.246.70.155 - PuTTY.exe"
WshShell.SendKeys "ssh nico{@}localhost{ENTER}"
WshShell.Run "ssh nico{@}localhost"
(in reply to
zerocool22
)
Post #: 3
RE: ssh @ doesnt read -
5/13/2008 4:05:14 AM
ebgreen
Posts: 4613
Score: 31
Joined: 7/12/2005
Status:
offline
You might also wnat to look at AutoIt. It does a much better job with sendkeys.
_____________________________
"... when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick
Goog places to start:
http://www.visualbasicscript.com/m_24727/tm.htm
http://www.visualbasicscript.com/m_47117/tm.htm
(in reply to
zerocool22
)
Post #: 4
If you found our site useful please link to us
<a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>
.
All Forums
>>
[Scripting]
>>
WSH & Client Side VBScript
>> ssh @ doesnt read
Page:
[1]
Jump to:
Select a Forum
All Forums
----------------------
[Welcome]
- - Forum Rules
- - Test Posting Messages
- - New Member Area/Introduction
[Scripting]
- - WSH & Client Side VBScript
- - WSH & Client Side VBScript Tutorial
- - Post a VBScript
- - Windows PowerShell
- - ASP
- - ASP.NET
- - Windows Script Components
[General Forum]
- - Other Programming/Scripting Languages
- - Suggestions & Feedback
- - Off-Topic Lounge
New Messages
No New Messages
Hot Topic w/ New Messages
Hot Topic w/o New Messages
Locked w/ New Messages
Locked w/o New Messages
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
Forum Software ©
ASPPlayground.NET
Advanced Edition
2.5.5 ANSI