Example scripts and tips (replaces Old Scripts & Tips archive)
Moderators: Dorian (MJT support), JRL, Phil Pendlebury
-
Grovkillen
- Automation Wizard
- Posts: 1131
- Joined: Fri Aug 10, 2012 2:38 pm
- Location: Bräcke, Sweden
-
Contact:
Post
by Grovkillen » Tue May 09, 2023 5:41 am
Code: Select all
Let>WINDOW_TITLE_TO_CHANGE=Explorer<---change this to the title of your target window
Let>WINDOW_TITLE_TO_SET=Yo!
GetWindowHandle>WINDOW_TITLE_TO_CHANGE,WINDOW_handle
LibFunc>User32,SetWindowTextA,DID_IT_CHANGE,WINDOW_handle,WINDOW_TITLE_TO_SET
MDL>DID_IT_CHANGE
Observe that some windows will not expose the Windows window frame and thus not comply to the standard = will not change its title this way. Another thing to remember is that the GetWindowHandle command only look for a window which match the title and the first one it is happy with get returned as a handle.
Last edited by
Grovkillen on Tue May 09, 2023 8:42 pm, edited 1 time in total.