Mark Hammond wrote :
#2 : the .exe must have a manifest that contains :
"""
... (I use the "python.exe.manifest" in which I add the following)
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel
level="requireAdministrator"
uiAccess="false"/>
</requestedPrivileges>
</security>
</trustInfo>
"""
I've put the manifest directly in the .exe using py2exe and :
'other_resources': [(24, 1, mymanifest)],
"24" is where the manifest should be.
I'm not sure this will work (and I'm not sure if you are saying it does or
doesn't work). To check it works, you should use the 'mt.exe' tool that
comes with the MSVC compilers and Platform SDKs to check it can extract a
manifest, and it is as you expect.
Actually this works fine, it was only an idea that you can use to make
pywin32 installable on XP without service pack :
* on XP it will have the classic behaviour (like with pywin32-210)
* on Vista, user will be prompted for an elevation
I suppose that you don't use py2exe but maybe you can add an embedded
manifest in your installer.
http://msdn.microsoft.com/en-us/library/bb756929.aspx
Yet another alternative is to use mt.exe *after* py2exe has run to embed the
manifest in the final executable.
Note however that it is rare you need the py2exe created executable to run
as administrator - it is the *installer* for the py2exe program that
generally needs this.
#3 Maybe someone could complete here ...?
Hope the above help.
Cheers,
Mark
_______________________________________________
python-win32 mailing list
python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32