Windows Script Host error with standby (1 Viewer)

putkonen

MP Donator
  • Premium Supporter
  • December 24, 2007
    152
    1
    Home Country
    Finland Finland
    TV-Server Version: tvengine3-02-18-2008--14-51h--Rev17406
    MediaPortal Version: MediaPortal-svn--02-18-2008--14-47-Rev17406.exe
    MediaPortal Skin: Xface
    Windows Version: XP Pro 2002 SP2
    CPU Type: AMD X2 BE-2300
    HDD: Samsung SATA 500 GB
    Memory: 2 GB DDR2
    Motherboard: Asus M2N-VM DH
    Motherboard Chipset: nForce 430
    Motherboard Bios: Award v1302
    Video Card: ASUS EAH2400
    Video Card Driver: 8.451.0.0
    Sound Card: SoundMAX integrated
    Sound Card AC3: coaxial out
    Sound Card Driver: 5.10.1.6110
    1. TV Card: Cinergy 1200 DVB-C
    1. TV Card Type: DVB-C
    1. TV Card Driver: 4.8.3.18
    2. TV Card: Cinergy 1200 DVB-C
    2. TV Card Type: DVB-C
    2. TV Card Driver: 4.8.3.18
    3. TV Card:
    3. TV Card Type:
    3. TV Card Driver:
    4. TV Card:
    4. TV Card Type:
    4. TV Card Driver:
    MPEG2 Video Codec:
    MPEG2 Audio Codec:
    Satelite/CableTV Provider:
    HTPC Case: Antec Fusion V2
    Cooling:
    Power Supply: Antec 430W
    Remote: MCE
    TV:
    TV - HTPC Connection: Sub-D

    Every now and then when I wake my PC from standby a Windows Script Host error window is displayed with the following information:

    Script: c:\program files\team mediaportal\mediaportal\restart.vbs
    line: 6
    char: 2
    error: not found
    code: 80041002
    source: SWbemObjectEx

    I have enabled the option to restart MP after standby, and this is displayed almost immediately when Windows has resumed. However this does not prevent MP from restarting.
     

    josch.hh

    MP Donator
  • Premium Supporter
  • March 29, 2008
    476
    77
    Hamburg
    Home Country
    Germany Germany
    Got an idea.

    Try to edit the restart.vbs file to ignore errors like that (just insert the red line):


    =========================================
    Option Explicit
    Dim process
    Dim shell

    on error resume next

    For Each process in GetObject("winmgmts:").ExecQuery("select * from Win32_Process where name='MediaPortal.exe'")
    process.Terminate(0)
    Next

    WScript.Sleep 1750

    set shell=createobject("WScript.Shell")
    shell.Run "mediaportal"

    ================================================
     

    peter448

    Portal Member
    June 7, 2008
    19
    0
    Brisbane
    Home Country
    Hi putkonen.

    I get exactly the same error (got one about 3 minutes ago when I pressed the power button on the unit to resume/bring it out of S3 Standby). I'm still only running RC1 with no SVN's. Intermittent problem for me. I haven't worked out why yet. I'm wondering if its a problem with having the option in MP Config ticked to restart MP each time AND having the same setting in MST. Might be a conflict. Haven't had a chance to look at it more closely, as each time I want to I cant make the fault happen.

    ...I don't want to go an change the .VBS file away from the MP standard. That just opens another world of pain when it comes to upgrades/updates.

    I'm pretty much waiting on RC2 to come out. Then I'll see if it still occurs. (I have a list of issues I am just putting up with at the moment that I will test under RC2. I'll report all, including this one, if they still exist).

    Regards, P
     

    tourettes

    Retired Team Member
  • Premium Supporter
  • January 7, 2005
    17,301
    4,800
    I see that error approx on once a month and my HTPC is resuming from S3 multiple times a day.

    peter448, could you please test the proposed fix? If its helping on your system I'm sure it will cure the issue I'm seeing (unfortunately I cannot test it as its occurs so rarely on my system). If it helps on your system I'll update the script in SVN (right after RC2 has been released).
     

    peter448

    Portal Member
    June 7, 2008
    19
    0
    Brisbane
    Home Country
    Hi tourettes.

    I'm happy to try out a fix. Exactly what fix are you talking about? Are you referring to josch.hh proposed fix or something else?

    If josch.hh fix, I can do this, although is it a good idea to simply ignore this error message as josch.hh seems to indicate this change will do?

    The fault happens on my HTPC normally daily, and often more than once a day.

    Regards, P
     

    josch.hh

    MP Donator
  • Premium Supporter
  • March 29, 2008
    476
    77
    Hamburg
    Home Country
    Germany Germany
    My proposal to fix this error is just a workaround. The script will simply ignore the errors and don't show them.
    Since i edited my restart script the error message is of course gone, but the other side is that the restart script does not work quit well at all. I realized that 50% of the time MP is simply not restarted. I wrote my own App in C# based on the "PowerEventHanlder" from "lkuech". This one works good, it also restarts the TVservice.
    If someone is interested i can post it here.
     

    Users who are viewing this thread

    Top Bottom