Anne Skeitzig
Anne Skeitzig

Reputation: 11

How to make specific window active

I want to know how to make a window (like Google Chrome, Notepad) active as If I were to click on it with the cursor. I've searched on Google but I couldn't find anything.

Can someone please tell me which function to use and what parameters it uses. Here's what I already tried using

WinWaitActive("Gestion de Voyage")

But WinWaitActive waits for the window to be active instead of activating it.

Upvotes: 0

Views: 1925

Answers (2)

Samoth
Samoth

Reputation: 1707

If it's for a specific Control inside a window, use ControlFocus.

Upvotes: 0

Tyler
Tyler

Reputation: 750

WinActivate should do what you're looking for.

https://www.autoitscript.com/autoit3/docs/functions/WinActivate.htm

What you're trying to do is change window focus.

Upvotes: 2

Related Questions