i got a trouble in my python function, i call a exe program what return result i use to excute in python code to detect the system mouse shape in the screen. The exe function will return diffrent result with each mouse shape state(arrow, hand). The problem is when python function call exe, appear Windows shell contain the result i want in, i read it by:
def check():
program = r'D:\vs project\aaaaaa\Debug\mousedetect.exe'
with subprocess.Popen([program], stdout=subprocess.PIPE, universal_newlines=True,shell=False) as p:
for line in p.stdout:
print(line)
In the position the Windows shell appear, it cover the screen so the value of mouse state in screen return is wrong. So, have anyway to run the exe to take result in Window shell with that Windows shell run in background?