> "C:\Tools\Python32\python.exe" "C:\Tools\Leo-4.10-final\launchLeo.py
> %*"
>
> Can you suggest what might be wrong?
The last set of double quotes looks wrong. Try:
"C:\Tools\Python32\python.exe" "C:\Tools\Leo-4.10-final\launchLeo.py" %*
In this case, none of the double quotes are needed, because the paths
have no embedded blanks, so this also should work:
C:\Tools\Python32\python.exe C:\Tools\Leo-4.10-final\launchLeo.py %*
Finally, unless you have a strong reason not to do so, I would suggest
adding the --gui=qttabs option::
C:\Tools\Python32\python.exe C:\Tools\Leo-4.10-final\launchLeo.py
--gui=qttabs %*
Edward
it's the trailing %*, use "%1" instead.
You want %* in a batch file. It passes all command line arguments to
the program being called.
"%1" passes just the file being clicked on, quoted for spaces etc.
When in a batch file %1 passes just the first command line parameter.
It is logical to expect %* to work for click file association as well,
but it doesn't. I don't know why.
--
-matt
Here is my setup...
Set up file type association:
C:\> ftype LeoFile=C:\Python27\pythonw.exe C:\apps\leo\launchLeo.py “%1″
C:\> assoc .leo=LeoFile
And put this leo.bat in %PATH%:
@start /b "Leo" C:\Python27\python.exe C:\apps\leo\launchLeo.py %*
--
-matt
neat, thanks for the tip.
oh, looks like it's problematic with portableapps.com suite 'cause of
high false-positive AV warnings... but maybe the same functionality
will be incorporated into the PA menu launcher. Cool.
http://portableapps.com/node/15583?page=4
--
-matt
Set up file type association:
C:\> ftype LeoFile=C:\Python27\pythonw.exe C:\apps\leo\launchLeo.py “%1″
C:\> assoc .leo=LeoFile
And put this leo.bat in %PATH%:
@start /b "Leo" C:\Python27\python.exe C:\apps\leo\launchLeo.py %*
> the docs have the wrong version, It should match the above:
> http://webpages.charter.net/edreamleo/install.html#installing-leo-on-windows
Good catch. I think rather than updating this for every release, I'll
try to generalize it a bit so people will understand what is intended.
The fix will probably be tricky: it's so hard to be clear and general
at the same time. Otoh, making instructions
Python-and-Leo-version-depenedent is pretty hopeless.
EKR
>>regsvr32 /i shell32.dll
Just note that this command does a lot more than update file
associations, and may undo some other customizations you've done
(default program for camera preview, shortcut wizard behaviour, ...)
Here are some things it does:
http://www.pcworld.com/article/126116/windows_tips_fix_windows_glitches_by_reregistering_your_dlls.html
cheers,
--
-matt
I got the association working on Windows 7 using:
>ftype LeoFile="C:\Python322\pythonw.exe" "C:\Program Files (x86)\Leo-4.9-final\launchLeo.py" "%1"
>assoc .leo=LeoFile
>regsvr32 /i shell32.dll