Advertisement

03.02.2004 at 04:40PM PST, ID: 20904805
[x]
Attachment Details

Which desktop is active when multiple users are logged in on XP

Asked by bjornsone in Windows Programming

Tags: impersonateloggedonuser, 2000, desktop, user

I have a program that runs as a service and it works just great on Windows 2000,
but it doesn't work properly on windows XP when multiple users are logged in.
I need to interact with explorer for purposes of using the tray icon, mounting remote
drives, displaying a GUI and other user oriented stuff.

I found several examples that use ImpersonateLoggedOnUser which gets the required
token by finding the process of "Explorer".  Now that there are multiple users, there
are multiple processes named "Explorer".  When the user selects "Switch User" how
do I detect the change and know which explorer is the active one??  Is impersonateLoggedOnUser
the right way to make function calls relate to one of the instances of Explorer or is
there a different way of changing how my service relates to multiple instances of
explorer??
Thanks a lot!Start Free Trial
[+][-]03.02.2004 at 05:47PM PST, ID: 10501234

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: Windows Programming
Tags: impersonateloggedonuser, 2000, desktop, user
Sign Up Now!
Solution Provided By: jkr
Participating Experts: 1
Solution Grade: A
 
 
[+][-]03.08.2004 at 05:09PM PST, ID: 10546026

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32