os.startfile: Why is there no arguments option?

Christian Wutte christian.wutte at gmx.at
Wed Oct 12 08:28:32 EDT 2011


On Oct 12, 11:45 am, Thomas Heller <thel... at ctypes.org> wrote:
>
> It is trivial to call ShellExecute with ctypes.
>

Yes, but it would be easier to use os.startfile() instead of
ctypes.windll.shell32.ShellExecute(), not? Further one must for sure
check the MSDN page for ShellExecute for the five parameters.
Then on error it is more comfortable that os.startfile already throws
an WindowsError.

[1] http://msdn.microsoft.com/en-us/library/windows/desktop/bb762153%28v=vs.85%29.aspx

Christian



More information about the Python-list mailing list