techtonik Posted March 31, 2006 Share Posted March 31, 2006 Given one putty console (plink to be correct). The console is probably unicode (at least UTF-8 is specified in putty session options). The task is to send ctrl-c to close window or ctrl-d command to logout from remote shell. Problem: control codes typed from keyboard are transmitted correctly, but with AutoIt v3.1.1 Send() function they don't seem to work at all. start "plink" plink session This opens a new console window to remote shell. And then. WinActivate("plink") WinWaitActive("plink") Send("{ASC 0067}") Send("+{ASC 67}") Send("!{ASC 67}") Send("^{ASC 67}") Send("+{ASC 0067}") Send("!{ASC 0067}") Send("^{ASC 0067}") ;Send("{CTRLBREAK}") Send("{ASC 0013}") This gives a string [serv001]$ CCCCCCC -bash: CCCCCCC: command not found [serv001]$ Link to comment Share on other sites More sharing options...
Xenobiologist Posted March 31, 2006 Share Posted March 31, 2006 HI, I cannot test it right now. Just a thought. Try ClipPut and right mouse. So long, Mega P.S.: I know that even when it should work, it is now good solution. :"> Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times Link to comment Share on other sites More sharing options...
techtonik Posted April 4, 2006 Author Share Posted April 4, 2006 HI,I cannot test it right now. Just a thought. Try ClipPut and right mouse.So long,MegaP.S.: I know that even when it should work, it is now good solution. :">Well, ControlClick("plink", "", "", "right") works fine to paste text into the window in this case. The problem is how to get "ctrl+c" to clipboard. =) Any ideas? Link to comment Share on other sites More sharing options...
Valuater Posted April 4, 2006 Share Posted April 4, 2006 (edited) ClipPut() can be utilized in command controls... ie ControlSend() see help 8) Edited April 4, 2006 by Valuater Link to comment Share on other sites More sharing options...
techtonik Posted April 6, 2006 Author Share Posted April 6, 2006 ClipPut()can be utilized in command controls... ie ControlSend() see help8)I can't find any information about it. Can you post a link? http://www.hiddensoft.com/autoit3/docs/functions/ClipPut.htm Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now