I wanna open pdf file from python console, I can do it with os.system(filename), it will open in adobe reader, but the problem is that os.system also opens a command prompt, is there another way that won't open command prompt?
Read the documentation thoroughly. The very first line of the os.system method is:
Execute the command (a string) in a subshell.
Knowing this, you can now seek alternate solutions, such as the subprocess module already mentioned.
We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.OkRead more