Re: [python-win32] Check if user has windows administrator

2008-01-15 Thread Simon Dahlbacka
Oh - and also how to either (a) force bdist_wininst executables to request elevation or (b) have the .msi generation be smarter wrt upgrading so installation is reasonable on Vista. Does anyone here have bdist_msi experience? For a), it should work by adding a manifest like this ?xml

[python-win32] Check if user has windows administrator privilege

2008-01-14 Thread Patrick Li
Hi, Does anyone know if there's a way to programmatically check to see if a user has windows administrator privilege? I need this to work in WinXP and Vista. Thanks in advance, Patrick ___ python-win32 mailing list python-win32@python.org

Re: [python-win32] Check if user has windows administrator privilege

2008-01-14 Thread Graeme Glass
On Jan 14, 2008 8:55 PM, Patrick Li [EMAIL PROTECTED] wrote: Hi, Does anyone know if there's a way to programmatically check to see if a user has windows administrator privilege? I need this to work in WinXP and Vista. Thanks in advance, Patrick

Re: [python-win32] Check if user has windows administrator privilege

2008-01-14 Thread Simon Dahlbacka
import ctypes print ctypes.windll.shell32.IsUserAnAdmin() (Courtesy of Thomas Heller - from a posting back in 2006) I have no idea if it will work on Vista. You will need to try it. It kinda works on Vista. If you're running from an elevated console then it will return 1, othervise (even

Re: [python-win32] Check if user has windows administrator privilege

2008-01-14 Thread Johri, Mayank (GTI)
14, 2008 1:55 PM To: python-win32@python.org Subject: [python-win32] Check if user has windows administrator privilege Hi, Does anyone know if there's a way to programmatically check to see if a user has windows administrator privilege? I

Re: [python-win32] Check if user has windows administrator

2008-01-14 Thread Tony Cappellini
Follow-up question. Why does type-ahead in PythonWin not show more functions after ctypes.windll. ? Is this because of late-binding??? Message: 3 Date: Mon, 14 Jan 2008 21:29:39 +0200 From: Graeme Glass [EMAIL PROTECTED] Subject: Re: [python-win32] Check if user has windows administrator

Re: [python-win32] Check if user has windows administrator

2008-01-14 Thread Mark Hammond
Follow-up question. Why does type-ahead in PythonWin not show more functions after ctypes.windll. ? Is this because of late-binding??? pythonwin basically just does a dir() of the name and the class, with special support for COM objects. See _AutoComplete() in pywin/scintilla/view.py -

Re: [python-win32] Check if user has windows administrator

2008-01-14 Thread Michel Claveau
Hi! force bdist_wininst executables to request elevation ? Sorry, not a real answer, (rather information). On Vista, install is detected by Vista, and run automatically with elevation. In theory. Because, in practice, it's true, or it's false, sometimes... Perso, for my install softs, I

Re: [python-win32] Check if user has windows administrator

2008-01-14 Thread Mark Hammond
me up. Mark Original message: - From: Simon Dahlbacka [mailto:[EMAIL PROTECTED] Sent: Tuesday, 15 January 2008 6:29 PM To: Mark Hammond Cc: [EMAIL PROTECTED]; python-win32@python.org; [EMAIL PROTECTED] Subject: Re: [python-win32] Check if user has windows administrator Oh