0

I am trying to open a Windows app with a python script, execute a loop of calls on it, retrieve the values and save them to a text file.

I used the bellow python script to open the application, I am not sure what need to be done next, is there a list of calls-commands that I can get from the application so I'll know which one to call? how do I navigate the application interface from python?

import os
import subprocess

cmd = 'C:/Program Files (x86)/path/to/my/application.exe'
p = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)

Thanks in advance!

1 Answers1

1

How do I navigate the application interface from python?

This sounds like the application that you are attempting to run has a graphical interface, you will not be able to use the subprocess module for this. The subprocess module should only be used to run command line applications or applications that have no output/interface at all.

Check out the answers to the following question for how you might be able to communicate with a GUI using Python: Make your program USE a gui


Is there a list of calls-commands that I can get from the application so I'll know which one to call?

This depends entirely on the application, without knowing which application you are running there is no way we will be able to provide this information.

Community
  • 1
  • 1
Andrew Clark
  • 202,379
  • 35
  • 273
  • 306