Solved

Administrator privilegues

Posted on 2004-09-21
5
250 Views
Last Modified: 2012-06-27
Hello experts.
How can I programatically determine if logged user has administrator's privilegues? I tried to do this with NetUserGetInfo function but it will not work on Windows98.
I have dll with my CheckPrivilegues function. This function calls NetUserGetInfo. Dll is linked to lib needed for NetUserGetInfo. The problem occurs in Windows98 where, because of that lib, my dll can't be used.

Thanks
0
Comment
Question by:pedja11
  • 2
  • 2
5 Comments
 
LVL 86

Accepted Solution

by:
jkr earned 50 total points
ID: 12113438
On Win98, there is no distinction between admins and non-admins, thus the check is pointless anyway.
0
 

Expert Comment

by:KBCRULE
ID: 12150509
what jkr said.
there won't be a way to limit a programs functionality based on win 9x user groups because there aren't any. If you're trying to make a network program, win nt 2k or xp would be your choices. If it's really important make it unusable on 9x.
0
 

Author Comment

by:pedja11
ID: 12151487
That was my question, how to make it unusable on 9x. I solved the problem. I load dlls only if it is necessary.
0
 
LVL 86

Expert Comment

by:jkr
ID: 12151611
Can you re-open this question? I will not accept a C grade for that.
0
 

Author Comment

by:pedja11
ID: 12156041
I don't know how can I re-open my question. Also, I can't see how can I cancel my question. You didn't understand my question. I knew that there are no user group on win 9x and I just wanted to know how to avoid using dlls with functions for network users which don't exist on win 9x. That's why C. Sure, it's not a problem to change it to A, but I just don't know how.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now