[EMAIL PROTECTED] wrote:
Hello people,

I'd like to have the functionality known from "real" executables that
if I drag-drop a file icon on top of the app, the app starts and has
the file's path as command-line argument.

However, this doesn't seem to work with Python scripts because Windows
sees those just as files, not apps.

Can this be done?

There may be fancier ways but...

... prefix the shortcut target with the python executable:

c:\python25\python.exe myscript.py

I've just tested this with a script which does this:

<code>
import os, sys

os.startfile (sys.argv[1])

</code>

and it works ok.

TJG
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to