Running lpr on windows from python
eryk sun
eryksun at gmail.com
Wed Apr 20 23:10:47 EDT 2016
On Wed, Apr 20, 2016 at 9:58 AM, Tim Golden <mail at timgolden.me.uk> wrote:
> If it's not, then try copying the lpr.exe to c:\windows\syswow64 and try
> again. (Or to some other place to which you have access).
WOW64 in Windows 7+ has a virtual "SysNative" directory that accesses
the native 64-bit system directory:
if '32bit' in platform.architecture():
lpr = os.path.join(os.environ['SystemRoot'], 'SysNative', 'lpr.exe')
else:
lpr = os.path.join(os.environ['SystemRoot'], 'System32', 'lpr.exe')
More information about the Python-list
mailing list