![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
|
Welcome to Vista Forums we are your forum for Windows Vista help and discussion. Whether you need help or just want to post an idea you have on Vista, this is the forum for you.
br> br> |
| |||||||
|
| | Thread Tools | Display Modes |
| | #1 (permalink) |
| Guest | app data in HKEY_LOCAL_MACHINE Hell, I write an app that stores data for all users into the HKEY_LOCAL_MACHINE\Software\... path. In Vista, somehow the data is stored but not visible in regedit under this path. What happens to it? Also, I used to let it run for all users with the HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run entry. This seems not to work any more. What can I do here to start an app for all users? Thanks, Jens |
My System Specs![]() |
| | #2 (permalink) |
| Guest | RE: app data in HKEY_LOCAL_MACHINE It got virtualized: http://msdn2.microsoft.com/en-us/library/aa965884.aspx "Jens Müller" wrote: > Hell, > > I write an app that stores data for all users into the > HKEY_LOCAL_MACHINE\Software\... path. In Vista, somehow the data is > stored but not visible in regedit under this path. What happens to it? > > Also, I used to let it run for all users with the > HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run entry. > This seems not to work any more. What can I do here to start an app for > all users? > > Thanks, > Jens > > |
My System Specs![]() |
| | #3 (permalink) |
| Guest | Re: app data in HKEY_LOCAL_MACHINE Hello, > It got virtualized: > http://msdn2.microsoft.com/en-us/library/aa965884.aspx Ok thanks. Now I have the problem that sometimes my app is run as administrator and sometimes not. Both times, the values that are read from the registry are different. How can I find out if my app has full rights or not? Thanks, Jens |
My System Specs![]() |
| | #4 (permalink) |
| Guest | Re: app data in HKEY_LOCAL_MACHINE You will need to inspect the token used to launch the app. Specificallly, you need to enumerate token groups and find out if the Administrator's group is present and not set to deny only. If so, you can write to HKLM. If not, you need to write elsewhere. "Jens Müller" wrote: > Hello, > > > It got virtualized: > > http://msdn2.microsoft.com/en-us/library/aa965884.aspx > > Ok thanks. Now I have the problem that sometimes my app is run as > administrator and sometimes not. Both times, the values that are read > from the registry are different. > > How can I find out if my app has full rights or not? > > Thanks, > Jens > > |
My System Specs![]() |
| | #5 (permalink) |
| Guest | Re: app data in HKEY_LOCAL_MACHINE IIRC, the IsUserAnAdmin API returns the right answer, true if you're elevated, false otherwise. In .NET, I suspect that WindowsPrincipal.IsInRole ("Administrators") does the right thing, although I haven't tested that one. -- Phil Wilson [Microsoft MVP Windows Installer] "Jens Müller" <jens_0.no.-spam@hotmail.com> wrote in message news:%23aqeViZaHHA.3612@TK2MSFTNGP04.phx.gbl... > Hello, > >> It got virtualized: >> http://msdn2.microsoft.com/en-us/library/aa965884.aspx > > Ok thanks. Now I have the problem that sometimes my app is run as > administrator and sometimes not. Both times, the values that are read from > the registry are different. > > How can I find out if my app has full rights or not? > > Thanks, > Jens |
My System Specs![]() |
| | #6 (permalink) |
| Guest | Re: app data in HKEY_LOCAL_MACHINE I don't think that will work. The problem is that in Vista you have admins that are currently admins, and admins that can become admins by accepting a UAC dialog. The IsUserAnAdmin API does not distinguish between the two. "Phil Wilson" wrote: > IIRC, the IsUserAnAdmin API returns the right answer, true if you're > elevated, false otherwise. In .NET, I suspect that WindowsPrincipal.IsInRole > ("Administrators") does the right thing, although I haven't tested that one. > -- > Phil Wilson > [Microsoft MVP Windows Installer] > > "Jens Müller" <jens_0.no.-spam@hotmail.com> wrote in message > news:%23aqeViZaHHA.3612@TK2MSFTNGP04.phx.gbl... > > Hello, > > > >> It got virtualized: > >> http://msdn2.microsoft.com/en-us/library/aa965884.aspx > > > > Ok thanks. Now I have the problem that sometimes my app is run as > > administrator and sometimes not. Both times, the values that are read from > > the registry are different. > > > > How can I find out if my app has full rights or not? > > > > Thanks, > > Jens > > > |
My System Specs![]() |
| | #7 (permalink) |
| Guest | Re: app data in HKEY_LOCAL_MACHINE > I don't think that will work. The problem is that in Vista you have > admins that are currently admins, and admins that can become admins > by accepting a UAC dialog. The IsUserAnAdmin API does not distinguish > between the two. That's ecactly the issue. Thanks anyway. Jens |
My System Specs![]() |
|
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Hkey_local_machine\components | Lazaruslong | Vista General | 1 | 08-22-2008 11:27 AM |
| KHz sample rate data and other key data fields missing from audio/media file properties view | tophy | Vista file management | 4 | 04-14-2008 09:35 AM |
| appdata-local-Application Data-Application Data-Application Data infinitum ad nauseum. WHY | keepout | Vista General | 15 | 09-15-2007 08:50 PM |
| HKEY_LOCAL_MACHINE\BCD00000000 ? | SwampYankee | Vista General | 3 | 09-12-2007 09:04 AM |
| hkey_local_machine\system\currentcontrolset\control\update | lostinto | Vista account administration | 0 | 01-03-2007 04:48 AM |
| Complimentary Industry Resources Vista Forums has joined forces with TradePub.com to offer you a new, exciting, and entirely free professional resource. Visit http://vistax64.tradepub.com today to browse our selection of complimentary Industry magazines, white papers, webinars, podcasts, and more across 34 industry sectors. No credit cards, coupons, or promo codes required. Try it today! |