Coder Social home page Coder Social logo

Comments (9)

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024
You can already receive session change notifications in services (via 
ServiceBase.OnSessionChange), which is where notifications are usually most 
useful, so I don't think this is a high priority.

Original comment by danports on 8 May 2011 at 12:39

  • Added labels: Priority-Low
  • Removed labels: Priority-Medium

from cassia.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024
Issue 47 has been merged into this issue.

Original comment by danports on 12 Feb 2012 at 12:00

from cassia.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024
WTSRegisterSessionNotificationEx (which allows monitoring of remote RD servers) 
requires Vista/2008. On older platforms, it may be possible to work around this 
using an undocumented function in winsta.dll, but I wouldn't count on that 
being easy to implement.

Original comment by danports on 15 Feb 2012 at 3:53

from cassia.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024
WTSWaitSystemEvent is another option, but the function is riddled with bugs -- 
sometimes notifications are dispatched twice, sometimes the WTS_EVENT_FLUSH 
value doesn't work. But it's a possibility for supporting remote XP/2003 
session notifications.

See:
- http://msdn.microsoft.com/en-us/library/windows/desktop/aa383856(v=vs.85).aspx
- http://www.remkoweijnen.nl/blog/2008/01/25/using-wtswaitsystemevent/

Original comment by danports on 15 Feb 2012 at 4:06

from cassia.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024

Original comment by danports on 15 Feb 2012 at 4:28

  • Added labels: Milestone-2.1

from cassia.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024
Use the same technique the Microsoft.Win32.SystemEvents class uses to create a 
hidden window to receive the relevant messages. WTSWaitSystemEvent doesn't 
provide as much information as WTSRegisterSessionNotificationEx. We could 
support WTSRegisterSessionNotification for local notifications on XP/2003, but 
it's probably not worth supporting notifications for remote systems on those 
platforms (unless we can dig up the relevant internal API easily -- XP/2003 are 
in the extended support phase already). There's 
WinStationRegisterNotificationEvent in winsta.dll, but it's not clear how that 
works without doing some spelunking.

Original comment by danports on 26 Feb 2012 at 2:45

  • Added labels: Estimate-8

from cassia.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024
hey there,
if you use a Windows Service you can easily receive session changes:
just override the OnSessionChange method and set CanHandleSessionChangeEvent to 
true.
This method is fairly spare documented although it works.

Original comment by [email protected] on 13 Sep 2012 at 2:03

from cassia.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024
Thanks for the comment. I actually use the OnSessionChange method in one of my 
projects and noted it in the first comment -- this improvement would be for 
non-service applications that want to receive session change notifications 
(e.g. a RD Services Manager type app).

Original comment by danports on 14 Sep 2012 at 2:42

from cassia.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 22, 2024
Issue 77 has been merged into this issue.

Original comment by danports on 23 Jan 2015 at 11:55

from cassia.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.