Jump to content

Witch Window Is Active

Recommended Posts


I am trying to make a simple script. The basic concept is it will automatically re size windows on to each monitor so I don't waste time re sizing them.


I understand how to re size them easily

WinMove('C:\Users\medic_000\Desktop\Monitor 1.au3 - SciTE-Lite', "", 1919, 0, 1280, 1040)

Here is what I need / am confused about I understand the winactive function but I need something that will give me the title of the window that is currently active so basically it would just set that as a variable and then re size witch ever window I have active currently


Any help on this would be greatly appreciated.



Share this post

Link to post
Share on other sites

From the helpfile:


WinGetTitle("[active]") returns the active window's title. 


Share this post

Link to post
Share on other sites

@Jos , Thak you. I didn't know this trick. I was used to use _WinAPI_GetForegroundWindow function. and get the title from then. 

My Contributions

UDF Link Viewer   --- A tool to visit the links of some most important UDFs 

 Includer_2  ----- A tool to type the #include statement automatically 

 Digits To Date  ----- date from 3 integer values

PrintList ----- prints arrays into console for testing.

 Alert  ------ An alternative for MsgBox 

 MousePosition ------- A simple tooltip display of mouse position

GRM Helper -------- A littile tool to help writing code with GUIRegisterMsg function

Access_UDF  -------- An UDF for working with access database files. (.*accdb only)


Share this post

Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...