I'd like to get the information of remote session source at the destination server with this function*1.
WTSQuerySessionInformation function (Windows)
It can be written by C# with DllImport. The value of
It takes some doing because the structure of
ppBuffer is changed depending on the specified value in
WTSInfoClass. Here is a struct when
WTS_CLIENT_ADDRESS structure (Windows)
If you get all the sessions except itself, you can use this function.
WTSEnumerateSessions function (Windows)
*1:It seems OK for launching app with UAC elevation