TVService PowerEventThread (1 Viewer)

josch.hh

MP Donator
  • Premium Supporter
  • March 29, 2008
    476
    77
    Hamburg
    Home Country
    Germany Germany
    Can someone tell me why are the PowerEvents in the file Service1.cs class TVService are handled via Window Broadcast Messages and not via the override of the SeriveBase PowerEvent methods?
     

    tourettes

    Retired Team Member
  • Premium Supporter
  • January 7, 2005
    17,301
    4,800
    by a mistake? Sorry, no actual knowledge, but at least it shounds like a mistake to me. Is there some issues that it causes?
     

    josch.hh

    MP Donator
  • Premium Supporter
  • March 29, 2008
    476
    77
    Hamburg
    Home Country
    Germany Germany
    by a mistake? Sorry, no actual knowledge, but at least it shounds like a mistake to me. Is there some issues that it causes?

    No issues. I only wanted to know. The PowerEvent handling is a very hard one if you do it this way. I thought that this may have some special meaning.

    I am currently interested in that, beacause my MPstandbyHandler windows service does not react on powerevents as fast as processes with a window handle which get the powerevents via a window message.
    This is misterious.

    Do you know the person who coded this class?
     

    josch.hh

    MP Donator
  • Premium Supporter
  • March 29, 2008
    476
    77
    Hamburg
    Home Country
    Germany Germany
    Sorry to comment my own thread, but i think i found the reason why the creator of the main TVService class did such a "hard" work to implement power event handling.

    After days of searching the Inet i found some comments that say "The PowerEvent Handling" in .Net Windows Services is BROKEN!
    This is what i also experienced during my coding.

    So stay away from it.

    Bye the way, the "Session Change Handling" is also broken...
     

    Users who are viewing this thread

    Similar threads

    If you’re planning to submit a pull request, let’s go through the list of issues and their solutions. I or someone from the team will create a Jira ticket, and for each ticket, you’ll make the changes and submit a pull request. This will be transparent and straightforward.
    If you’re planning to submit a pull request, let’s go through the list of issues and their solutions. I or someone from the team...
    I'm very glad to see that mediaportal 1 is on github, where ordinary devs with github accounts can make contributions. Please can...
    Replies
    7
    Views
    1K
    Reading through your code, I can see it's more than a couple steps above my paygrade. :cry:
    Reading through your code, I can see it's more than a couple steps above my paygrade. :cry:
    I used to run the TVService under the "NT Service\TVService" account to follow least privileges principal (not exposing my whole...
    Replies
    3
    Views
    2K
    Are the media/video folders on the Mint host?
    Are the media/video folders on the Mint host?
    I've used Mediaportal for years on a Windows Host with restricted online-access. Lately I reinstalled...
    Replies
    1
    Views
    1K
    As Alexander Pope said: A little learning is a dangerous thing, and Dr Google explains this as: The quotation warns that superficial knowledge of a subject can make people arrogant or foolish, suggesting one should either learn deeply or not at all. "Superficial", and "arrogant or foolish" would be me :eek: . However... I would...
    As Alexander Pope said: A little learning is a dangerous thing, and Dr Google explains this as: The quotation warns that...
    I have just discovered that I can no longer receive any of the independent radio channels broadcast on DVB-T in the UK. In...
    Replies
    12
    Views
    4K
    Thank, very helpful. My download was done today from the link on Download MediaPortal for free! - MEDIAPORTAL but is the initial release MediaPortalSetup_x86_1.37.000_2025-04-14-08-37.zip. The page MediaPortal 1.37 Release - MEDIAPORTAL has a more recent link, MediaPortalSetup_x86_1.37.000_2025-05-03-18-19.zip. I've now installed...
    Thank, very helpful. My download was done today from the link on Download MediaPortal for free! - MEDIAPORTAL but is the initial...
    I updated to 1.37 (x86) today, and the TV service is now failing to start. TVService.log has this line: Tvservice stopped due to...
    Replies
    2
    Views
    1K
    Top Bottom