Crivens Posted January 10, 2007 Posted January 10, 2007 Ok, so I've just discovered AutoIt. Very nice. I've already used it for a few little useful functions but am still very much a beginner. Anyways I'll explain the situation and see what everyone reckons. Basically I connect over a VPN to a computer in the UK (I'm in Cyprus) and use a session to provide access to terminal emulators (NetTerm is one that has been used in the past, although we use our own these days), which I use to connect to a variety of sites for coding of travel systems (I'm a programmer for companies such as Thomsons, Lunn Poly, First Choice etc). Anyway, what I want is my session setup to automatically load (or at least when I'm ready to run an AutoIt script). This includes such things as VPN software, Outlook, IE, and about 4 terminal emulators. Now I can do most of it, but the terminal emulators are the problem. I basically want one in each corner. At the minute they all load in the same location of the screen and the software only remembers one "session". So basically I need to know how to say exactly where the window will appear. Or at least how to load it then move it to another location (assume some sort of grabbing of window handle then using a command to move it somewhere else). Finally does AutoIt have a command to send keyboard commands to a specific window. Basically I want to be able to login automatically into the terminal emulators. Because there is a slight pause before the password can be entered then a wait command would be useful, but is there a way to grab text from the emulator and then when it sees "Password:" that it can send the password? Cheers
herewasplato Posted January 10, 2007 Posted January 10, 2007 ...Or at least how to load it then move it to another location (assume some sort of grabbing of window handle then using a command to move it somewhere else). Finally does AutoIt have a command to send keyboard commands to a specific window...Welcome to the forums.Take a look at WinMove (and/or WinGetHandle) in the help file.Also look at the Run command and the standard_i/o_flag options.If you have problems/questions with your code, post a small snippet of it... enjoy [size="1"][font="Arial"].[u].[/u][/font][/size]
CoePSX Posted January 10, 2007 Posted January 10, 2007 - Use Run to open one emulator.- Use WinWait to wait for it's window.- Then move that window to a corner using WinMove. Use the @DesktopWidth and @DesktopHeight macros to calculate the corners based on the window size (WinGetSize).- Do that again with each one of the other emulators. [quote name='Valik' post='301213' date='Jan 31 2007, 10:36 PM']You seem to have a habit of putting things in the wrong place. I feel sorry for any female you attempt to have sex with.[/quote][font="Lucida Sans Unicode"]╔══════════════════════════════╗║░░██░░░░░░░░██░░███░░░████░░░█║║░█░░█░░██░░█░░█░█░░█░█░░░░█░█░║║░█░░░░█░░█░████░███░░░██░░░█░░║║░█░░█░█░░█░█░░░░█░░░░░░░█░█░█░║║░░██░░░██░░░██░░█░░░░███░█░░░█║╚══════════════════════════════╝[/font]
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