Re: Remote?
Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance
Hallo Stefan!
Wie bekomme ich heraus, ob der User lokal eingeloggt ist,
oder remote? zb RemoteDesktop...
Du musst "ProcessIdToSessionId" mit Deiner "GetCurrentProcessId"
aufrufen. Wenn Ein Wert != 0 zurückkommt, läuft Deine App auf einem TS
(oder via Remote-Desktop; was prinzipiell das gleiche ist).
Das ist so nicht ganz richtig. Unter XP haengt die Session Id davon ab,
wie sich der erste user nach dem Start einloggt. Tut er das remote nach
dem booten, hat die session die ID 1, tut er das lokal, erhaelt sie die
session id 0 (der Konsole). Loggt sich also ein user lokal ein, sperrt
dann die Maschine und uebernimmt schliesslich die Session dann per
Remote Desktop von einem anderen Rechner uebers Netzwerk, hat er nach
wie vor session Id 0 aber ist zweifellos remote auf der Maschine.
Dasselbe geht mit der Konsole vom W2K3 Server auch.
Dazu kann man dann "GetSystemMetrics" verwenden, oder?
--
Greetings
Jochen
My blog about Win32 and .NET
http://blog.kalmbachnet.de/
.
Relevant Pages
- Re: Server 2008: Shared or concurrent remote desktop access
... Full Control with user's permission ... Full Control without user's permission ... View Session without user's permission. ... Is there any way at all with Windows Server 2008's remote desktop (or other ... (microsoft.public.windows.server.general) - Re: Great SWT Program
... the session running if the screen client loses its connection or shuts ... Given that I do a lot of remote work over the internet at large, ... but consumes a large amount of bandwidth when updating ... (comp.lang.java.programmer) - RE: Spying, admin to user login?, Is it possible?
... shadow session could not be created directly on Windows XP computer. ... you could active only one user session at one time ... you need to remote desktop to a Windows 2003 ... Microsoft also publishes a KB to describe this work around in detail. ... (microsoft.public.windows.server.sbs) - RE: Printer share name changes HELP!
... occurs after the session has disconnected and upon reconnect it then connects ... you have two remote PCs connecting to Windows 2000 Server ... In a Microsoft Windows 2000-based Terminal Services session, ... (microsoft.public.windows.terminal_services) - Re: RDP using RPC over HTTP
... Remote Networking Technology Support Site - ... >server as Exchange. ... >The question is can you get the TSWeb to use RPC over HTTP. ... >start an session of RD from there, kind of RD inside RD as you suggested? ... (microsoft.public.windowsxp.work_remotely) |
|