我想通过python代码打开VM Player应用程序,我必须导入/打开VM文件,但是每当我尝试通过subprocess.Popen(self.vmware_path)python代码行打开应用程序时,它都会在x,y处随机调用该应用程序位置。
我已经研究了子过程.Popen(STARTUPINOF)中的一些可能性,但是我无法理解STARTUPINFO类的概念。通过os.system,我可以打开应用程序,但无法在预定义的位置进行操作。
# print pyautogui.position()
# print pyautogui.size() # current screen resolution width and height
# pyautogui.PAUSE = 1
# pyautogui.FAILSAFE = True
subprocess.Popen(self.vmware_path)
# si = subprocess.STARTUPINFO()
# si.dwFlags = subprocess.STARTF_USESHOWWINDOW
# si.wShowWindow = 3
我需要的是,