How does A_IsAdmin work?
- PuzzledGreatly
- Posts: 1303
- Joined: 29 Sep 2013, 22:18
How does A_IsAdmin work?
I have two user accounts, one is an admin account the other is a regular account. If I run a script containg the line msgbox %A_IsAdmin% I get the answer 0 each time. Shouldn't a script run under my Admin acoount have admin rights? Thanks.
Re: How does A_IsAdmin work?
A_IsAdmin is true if script is running as administrator (right click, RunAs Administrator)
- PuzzledGreatly
- Posts: 1303
- Joined: 29 Sep 2013, 22:18
Re: How does A_IsAdmin work?
Thanks, how do I determine if the user has Admin rights?
- LinearSpoon
- Posts: 156
- Joined: 29 Sep 2013, 22:55
Re: How does A_IsAdmin work?
This looks promising, but I've not tried it myself.
How to tell if the current user is in administrators group
How to tell if the current user is in administrators group
Re: How does A_IsAdmin work?
viewtopic.php?p=25618#p25618PuzzledGreatly wrote:Thanks, how do I determine if the user has Admin rights?
- PuzzledGreatly
- Posts: 1303
- Joined: 29 Sep 2013, 22:18
Re: How does A_IsAdmin work?
Thanks for the link, just me. That method works well.
Re: How does A_IsAdmin work?
Why is A_IsAdmin true when the script is not run as administrator?Coco wrote:A_IsAdmin is true if script is running as administrator (right click, RunAs Administrator)
-
- Posts: 44
- Joined: 18 Aug 2016, 22:56
Re: How does A_IsAdmin work?
1imustbeamoron wrote:what does this return?
Code: Select all
MsgBox % DllCall("Shell32.dll\IsUserAnAdmin")
Does that mean everything is run as admin?
Who is online
Users browsing this forum: inseption86, mikeyww and 458 guests