Old 13th March 2003, 10:23   #1
cybereka
Junior Member
 
Join Date: Mar 2003
Location: India
Posts: 22
Angry Any way to find the user privilages

Hai all,
Is there any way to find the user has got the administrator privilege. And only if he got that the installation should continue otherwise i need to abort the installation by just giving his the reson. Is there any way to do this? Thanks a lot.
cybereka is offline   Reply With Quote
Old 13th March 2003, 11:12   #2
Mosestycoon
Senior Member
 
Mosestycoon's Avatar
 
Join Date: Feb 2003
Location: outter space
Posts: 139
Send a message via ICQ to Mosestycoon
DLL in the plugin-folder

Check out your plugin-folder of your version, there is a userinfo.dll and somewher there is an example script within the package of latest NSIS

MO

---- [U P D A T E] ----

The script is in the folder:
Path\to\NSIS\Contrib\UserInfo



Cheers
Mosestycoon is offline   Reply With Quote
Old 2nd April 2003, 13:33   #3
bene42
Junior Member
 
Join Date: Apr 2003
Posts: 3
Re: DLL in the plugin-folder

Hi,

Quote:
Originally posted by Mosestycoon
Check out your plugin-folder of your version, there is a userinfo.dll and somewher there is an example script within the package of latest NSIS
this DLL works fine, exept on Win9x with Novell-Client. The User has the right to install everything (no admin), but the script returns a username and a Usergroup depends on Novell. Maybe there is a way to change this behavior.

Bene
bene42 is offline   Reply With Quote
Old 2nd April 2003, 14:05   #4
Joost Verburg
NSIS MUI Dev
 
Join Date: Nov 2001
Posts: 3,717
Win9x is no multi-user platform. Everyone has the right to install software.
Joost Verburg is offline   Reply With Quote
Old 2nd April 2003, 14:24   #5
bene42
Junior Member
 
Join Date: Apr 2003
Posts: 3
Quote:
Originally posted by Joost Verburg
Win9x is no multi-user platform. Everyone has the right to install software.
But with Novel-Client UserInfo returns a Username and a Usergroup:
The example ends up here:
StrCmp $1 "User" 0 +3
MessageBox MB_OK 'User "$0" is just a regular user'
and NOT here:
Win9x:
# This one means you don't need to care about admin or
# not admin because Windows 9x doesn't either
MessageBox MB_OK "Error! This DLL can't run under Windows 9x!"

Bene
bene42 is offline   Reply With Quote
Old 2nd April 2003, 15:05   #6
Joost Verburg
NSIS MUI Dev
 
Join Date: Nov 2001
Posts: 3,717
You can add a registry check for Win9x.
Joost Verburg is offline   Reply With Quote
Old 2nd April 2003, 15:18   #7
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Are you saying Novel installs advapi32.dll?

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 3rd April 2003, 09:48   #8
bene42
Junior Member
 
Join Date: Apr 2003
Posts: 3
Quote:
Originally posted by kichik
Are you saying Novel installs advapi32.dll?
Yes, I think so. advapi32.dll exist on the system.

Quote:
Originally posted by Joost Verburg
You can add a registry check for Win9x.
uname -a?
Windows is not my best known OS

Bene
bene42 is offline   Reply With Quote
Old 3rd April 2003, 12:28   #9
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
The latest version in CVS now always returns Admin if it's on Windows 9x and the DLL actually loads. Can anyone please test if the DLL loads on Windows 95? If it doesn't load you'll get a message saying the DLL is not built for Windows 9x (using the Contrib\UserInfo\UserInfo.nsi example).

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump