sys.argv problem in Win 2k
Duncan Booth
duncan at NOSPAMrcp.co.uk
Fri Apr 25 03:47:19 EDT 2003
I wrote:
>> D:\temp>ftype Python.File
>> Python.File=D:\Python22\python.exe "%1" %*
abpillai at lycos.com (Anand B Pillai) wrote in
news:bd993a2f.0304242310.586305df at posting.google.com:
> F:\users\anand\LocalWorkspaces\ResModWS>ftype Python.File
> Python.File=D:\Python22\python.exe "%1"
>
Spot the difference.
The "%1" passes the name of the script to python.exe, the %* passes all the
other arguments. Without the %* windows will simply drop the other
arguments on the floor.
--
Duncan Booth duncan at rcp.co.uk
int month(char *p){return(124864/((p[0]+p[1]-p[2]&0x1f)+1)%12)["\5\x8\3"
"\6\7\xb\1\x9\xa\2\0\4"];} // Who said my code was obscure?
More information about the Python-list
mailing list