PIL + show() + Vista

Tim Golden mail at timgolden.me.uk
Fri Nov 30 12:06:55 CET 2007

Méta-MCI (MVP) wrote:
> Hi, Tim!
> You are right, for  shimgvw.dll  (on XP / 2000, or some Vista). But 
> others Vista (ou users practice) had associate  images with 
> WindowsPhotoGallery.exe.
> But  shimgvw.dll already exist.
> I found that this line:
>         command = 'start "%s" /wait %s\\System32\\rundll32.exe 
> %s\\System32\\shimgvw.dll ImageView_Fullscreen %s && del /f "%s" ' % 
> (title,os.environ['SYSTEMROOT'],os.environ['SYSTEMROOT'],file,file)
> launch a "Photo Gallery" who respect the WAIT.
> For me (and my users), it's a solution.  Perhaps others PIL's users can 
> read that with interest.

I'm glad you found a solution. I think my point was that
you can use the FindExecutable API to determine whatever
is associated and use that (special-casing the shimgvw DLL
to use RunDLL). Obviously, if that executable doesn't
honour the wait then you're stuck, so maybe using shimgvw
universally is the solution.


More information about the Python-list mailing list