'Is any way to run PyautoGUI in another window?

In Windows 10, we can create new windows by pressing WIN+TAB. Is there any way to run PyautoGUI for a specific window?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source