I am developing a code using pyautogui where i detect an event in the window "A" and them, with alt+tab, execute an action in the window "B". I would like to know if it is possible to do this, but with the window "A" minimized, so it doesnt have to alt+tab all the time (the solution doesnt necessary has to be with pyautogui).
If you intended to use the locate function with pyautogui, whether or not it's LocateAll or just locate, it has to see that same matching image on screen first then you can adjust the confident to your needs. What you're asking is really hard to answer without knowing what you wanted to do, for example if you wanna do that on browser then you can replace it by selenium for example, for normal window can just make a script to let it switch tab for you then let pyautogui detect and do it job
Pyautogui locate functions in a minimized window