This forum has migrated to Microsoft Q&A. Visit Microsoft Q&A to post new questions.
Hi,
I need code for:
1. How can I check if computer is in remote desktop connection?
2. When I know that a computer in remote connection, how can I know the name of computer that connected by RDC?
Thank's
Alexei
I guess you want your application to check whether it is run in an RDP session? Then:
1. GetSystemMetrics(SM_REMOTESESSION)
2. WTSQuerySessionInformation
See also: http://groups.google.com/group/microsoft.public.dotnet.framework.interop/browse_thread/thread/25af73b2dbf7a7c9