We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you a podcast all about Citrix Workspace, moving to the cloud, and analytics & intelligence. Episode 2 coming soon!Listen Now

x

Desktop ID

RodionP
RodionP asked
on
Medium Priority
413 Views
Last Modified: 2008-02-01
Hi,

I need to be able to identify unique desktops.

I have a windows service and it is independant of any desktop and there are application that are making calls to this service via remoting. I need to be able to file these calls, each call can come from a specific machine, username and desktop, and I need to be able to retrieve that information somehow.

I use Environment.Username and Environment.MachineName for first 2 parameters, but i can't get the Desktop ID...

I tried using GetProcessWindowStation in user32.dll but it doesn't return unique id when I login to the same workstation with the same username, this GetProcessWindowStation function returns the same number... thus I cannot differentiate between desktops.

Can someone please help me... I spend hours and hours searching the internet and I can't find anything
Comment
Watch Question

Commented:
Hi RodionP,

this is a example very good. It has some methodsfor your problem: http://www.codeproject.com/csharp/csdesktopswitching.asp

Good luck,
VINHNL

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.