Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #92910
| From | Dennis Lee Bieber <wlfraed@ix.netcom.com> |
|---|---|
| Subject | Re: Opening PDF Using subprocess.Popen Failing |
| Date | 2015-06-20 09:50 -0400 |
| Organization | IISS Elusive Unicorn |
| References | <4857b9a4-386f-4ae4-861b-09a9564557c7@googlegroups.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.659.1434808250.13271.python-list@python.org> (permalink) |
On Fri, 19 Jun 2015 10:24:56 -0700 (PDT), Naftali <nmichalowsky@gmail.com>
declaimed the following:
>It actually doesn't fail but it 'cannot open in protected mode' (see here http://blogs.adobe.com/dmcmahon/2012/07/27/adobe-reader-cannot-open-protected-mode-due-to-a-problem-with-your-system-configuration/)
>
>I am using subprocess.Popen("AcroRe32.exe /n <file.pdf>") which is the actuall adobe reader command I'd issue on the command line to open the pdf (the /n option opens it the file in a new instance of reader).
>
>Now, when I issue the command straight from powershell, the pdf opens no problem, but when I open in my script (whether a .py or py2exe) I get the pop up complaining that the PDF cannot be opened in 'protected mode.' One of the options is to open it anyways, which works.
>
Are you running the Python script within PowerShell?
As I recall, PowerShell was deliberately designed with all sorts of
security blocks to prevent "malicious executables"... One has to enable
execution levels to allow for PowerShell scripts to even be run (invoked at
PS command line, but not from within another script, etc.).
Is there any chance that such a restriction is being passed through to
the subprocess environment?
--
Wulfraed Dennis Lee Bieber AF6VN
wlfraed@ix.netcom.com HTTP://wlfraed.home.netcom.com/
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Opening PDF Using subprocess.Popen Failing Naftali <nmichalowsky@gmail.com> - 2015-06-19 10:24 -0700
Re: Opening PDF Using subprocess.Popen Failing Laura Creighton <lac@openend.se> - 2015-06-19 20:17 +0200
Re: Opening PDF Using subprocess.Popen Failing Naftali <nmichalowsky@gmail.com> - 2015-06-19 11:45 -0700
Re: Opening PDF Using subprocess.Popen Failing Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2015-06-20 09:50 -0400
Re: Opening PDF Using subprocess.Popen Failing Naftali <nmichalowsky@gmail.com> - 2015-06-20 20:14 -0700
Re: Opening PDF Using subprocess.Popen Failing Robin Becker <robin@reportlab.com> - 2015-06-22 11:33 +0100
Re: Opening PDF Using subprocess.Popen Failing Robin Becker <robin@reportlab.com> - 2015-06-22 11:55 +0100
Re: Opening PDF Using subprocess.Popen Failing Naftali <nmichalowsky@gmail.com> - 2015-06-22 06:15 -0700
Re: Opening PDF Using subprocess.Popen Failing Laura Creighton <lac@openend.se> - 2015-06-22 15:37 +0200
Re: Opening PDF Using subprocess.Popen Failing Naftali <nmichalowsky@gmail.com> - 2015-06-22 07:23 -0700
Re: Opening PDF Using subprocess.Popen Failing Naftali <nmichalowsky@gmail.com> - 2015-06-22 09:13 -0700
csiph-web