Re: Python 2.7 and cmd on Windows 7 64 (files lost)

2011-06-24 Thread Martin v. Loewis
Therefore, Windows has a trick for mark the file like visible, or not, in 32 mode. What trick? It's called file system redirection. When you access \windows\system32 in a 32-bit process, you *actually* access \windows\syswow64, which has entirely different files. The same also happens for

Python 2.7 and cmd on Windows 7 64 (files lost)

2011-06-23 Thread Michel Claveau - MVP
Hi! (sorry for my bad english...) On Win 7 64 bits: Command-Line CD \Python27 dir C:\Windows\System32\SoundRecorder.exe:== OK Python.exe import os os.system(dir C:\\Windows\\System32\\SoundRecorder.exe) == Do not found the file !!! and os.system(cmd /k) then dir

Re: Python 2.7 and cmd on Windows 7 64 (files lost)

2011-06-23 Thread Thorsten Kampe
* Michel Claveau - MVP (Thu, 23 Jun 2011 08:33:20 +0200) On Win 7 64 bits: Command-Line CD \Python27 dir C:\Windows\System32\SoundRecorder.exe:== OK Python.exe import os os.system(dir C:\\Windows\\System32\\SoundRecorder.exe) == Do not found the file !!! and

Re: Python 2.7 and cmd on Windows 7 64 (files lost)

2011-06-23 Thread Tim Golden
On 23/06/2011 07:33, Michel Claveau - MVP wrote: Hi! (sorry for my bad english...) On Win 7 64 bits: Command-Line CD \Python27 dir C:\Windows\System32\SoundRecorder.exe:== OK Python.exe import os os.system(dir C:\\Windows\\System32\\SoundRecorder.exe) == Do not found the

Re: Python 2.7 and cmd on Windows 7 64 (files lost)

2011-06-23 Thread Thorsten Kampe
* Tim Golden (Thu, 23 Jun 2011 08:31:26 +0100) Certain commands, including dir and copy are not executables in their own right, but merely subcommands of cmd.exe. Right, internal commands. You've got two options in Python: os.system (rcmd /c dir c:\windows) os.system automatically

Re: Python 2.7 and cmd on Windows 7 64 (files lost)

2011-06-23 Thread Tim Golden
On 23/06/2011 09:08, Thorsten Kampe wrote: * Tim Golden (Thu, 23 Jun 2011 08:31:26 +0100) Certain commands, including dir and copy are not executables in their own right, but merely subcommands of cmd.exe. Right, internal commands. You've got two options in Python: os.system (rcmd /c

Re: Python 2.7 and cmd on Windows 7 64 (files lost)

2011-06-23 Thread Michel Claveau - MVP
Re ! This is because 32-bit processes (Python, 32-bit cmd) cannot see the 64-bit DLLs in System32. Thanks. You are right... but it is not enought. This command: echo %PROCESSOR_ARCHITECTURE% give the statut: 32: x86 64: AMD64 and DIR C:\Windows\System32\SoundRecorder.exe is OK