Solved

Accessing the Access rights of the User

Posted on 2002-06-13
6
130 Views
Last Modified: 2010-04-04
Hello everyone anybody can help me here?

We have a problem here coz we are making a SOFTWARE INSTALLER PROGRAM (for our multimedia products).
When installing our program (when on WINDOWS XP is used)
only the SYSTEM ADMINISTRATOR or the POWER USER have the full access of the system AND CAN write or remove installed programs in the system, BUT HOW ABOUT if the user is an ORDINARY USER. he cant install our software coz he/she dont have rights to install coz it will be a readOnly system. how can i change the system rights or how can i write files in the system and then make it restore the default?

for example i cant write from the WINDOWS DIRECTORY how can i make myself having a full access and then turn it back to its original rights.

anybody can help me with this one. and can give me CODES FOR IT. so that i can use it right away.

example

Procedure changeAccess(DirectoryPath;kinds_rights)
Procedure EditableFiles(Filename;kinds_rights)

DirectoryPath - any directory specified
Filename      - filename of the file you want to access
Kinds_rights  - can be readonly or writetable etc.

0
Comment
Question by:girlswants_me
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 

Author Comment

by:girlswants_me
ID: 7076911
help us please
0
 
LVL 14

Expert Comment

by:DragonSlayer
ID: 7077006
write it to
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall

instead... coz every user can access that... unless of course, the System Admin has completely disabled registry access.
0
 
LVL 44

Expert Comment

by:CrazyOne
ID: 7077395
Well this is a tough call. Consider that the SysAdmin may not want this to be done. They may have even setup these user's with the implicit intent of disallowing anything to be installed or uninstalled by that user. What you are asking seems as a way to circumvent the reason the Deny access is in place to begin with.


The Crazy One
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 14

Expert Comment

by:DragonSlayer
ID: 7077411
... unless of course, you save the uninstallation details in an .ini file in the program folder, and add a shortcut to the uninstaller to the start menu as well
0
 
LVL 20

Accepted Solution

by:
Madshi earned 200 total points
ID: 7077554
Hey, what would NT security be worth, if an ordinary user could change his own rights to be administrator like? You're joking, aren't you?

You have to live with the restrictions, that is: Don't use the Windows directory, don't use HKEY_LOCAL_MACHINE. Instead put everything into "C:\Program Files" and write to HKEY_CURRENT_USER. That's the way to go.

If your program can't run without putting something into the Windows directory (why???), you have to ask the user to let the administrator install the program.

Sorry for the bad news.

Regards, Madshi.
0
 

Author Comment

by:girlswants_me
ID: 7077573
tHANK you so much MADSHI, we realized it all.
so to install programs you must see the system admin.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Delphi: ForceDirectory plain function 7 77
update joined tables 2 69
shape, triangle, dbctrlgrid 3 42
Firemonkey Queue list 1 48
A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

740 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