Obtaining the name of the remote computer connecting to Terminal Services 
Author Message
 Obtaining the name of the remote computer connecting to Terminal Services

Hi all,

How can I programmatically (API call?) obtain the name of the remote
client computer connected to a Terminal Services session? In other
words, when the user logs into Windows Terminal Services from a remote
computer, and then they start my application (which they see in their
TS session but which runs on the server really), I would like to be
able to log into a file (from my application on the server) the name
of the computer on which the session is running (the computer used by
the remote user). How can this be done? I'm sure it can be done
because Windows itself can redirect printing and sounds to the remote
computer...

Any help would be appreciated.
Thanks.
Al



Fri, 27 May 2005 23:21:55 GMT  
 Obtaining the name of the remote computer connecting to Terminal Services
Hi,

You can use the WTSQuerySessionInformation() API to get the terminal
session information. For more information about this API, you can check the
following documentation:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/term...
rmserv/wtsquerysessioninformation.asp?frame=true

Regards,
Elan Zhou
This posting is provided "AS IS" with no warranties, and confers no rights.
Got .Net?  http://www.gotdotnet.com



Sat, 28 May 2005 16:24:05 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Get computer name and IP from remote computer

2. Remote Terminal Services, RDC, Citrix and software licensing

3. Obtaining RAM amount and Disk Space from a remote computer

4. Terminal Service Client Name/User

5. Getting the Terminal Services Client Machine Name

6. How to obtain local network NetBIOS computer names?

7. Obtaining Computer Name

8. Using WMI to obtain dependent services (restarting services and all dependent services)

9. How to obtain a computer name?

10. how can I obtain all names of computers from workgroup

11. starting nt service on remote computer

12. How to receive a remote computers Windows NT Services in VB 5.0

 

 
Powered by phpBB® Forum Software