Click here to Skip to main content
14,326,728 members
Rate this:
Please Sign up or sign in to vote.
See more:
Hello world ;)
I am facing a problem for quite a while now, hoping anybody here has an idea how to deal with it.

We have a application that is distributed to different workstations in our company.
It has an updater which basically copies the new files to their destination folders on the client machines (XP, Win 7).

A requirement was that the application is copied into the "Programms" folder which is, as we all know, a protected one.

I used impersonation via LogonUser of the advapi32.dll, passing an admin user login as parameters.

It worked fine for the XP machines, unfortunately not for the Win 7 ones.

Could anybody be so kind and tell me how impersonation is archieved on win 7 machines?
I digged through Google for quite a while now but nothing really worked.
I also added <requestedExecutionLevel level="requireAdministrator" uiAccess="false" /> in the manifest etc, no result but maybe I am just on the wrong path.

Any "enlightments" are kindly appreciated,


1 solution

Rate this:
Please Sign up or sign in to vote.

Solution 1

I am not sure this can be done. Win7 sucks.
hoernchenmeister 22-Jul-11 2:25am
I know what you mean ;)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100