No announcement yet.


  • Filter
  • Time
  • Show
Clear All
new posts


    Thought I would start this

    I ran it and got this error--8/15/2006 5:46:47 PM ~!~Info~!~Running script in background: ProcessWatcher.vb
    8/15/2006 5:46:57 PM ~!~PROC.STATUS~!~Error in Trace = Cannot create ActiveX component.
    8/15/2006 5:46:57 PM ~!~PROC.STATUS~!~found = False
    8/15/2006 5:46:59 PM ~!~PROC.STATUS~!~Error in Trace = Cannot create ActiveX component.
    8/15/2006 5:46:59 PM ~!~PROC.STATUS~!~C:\Program Files\HomeSeer 2\Speaker.exe could not be started due to error, rc = 0


    ps Here is my mods
    PHP Code:
    Sub Main(parm as object)
    Dim targetName As String "Speaker.exe" ' line 18
            Dim targetPath As String = "C:\Program Files\HomeSeer 2\"
        Dim strComputer As String = "andrew" ' 
    hostname of target computer use "." for local computer 
    FB Page -

    HSTouch Layouts -

    So, you got the errors after your mod?

    I was able to run this OK with your mods. But, I did notice that the Exists function needs to be case insensitive in the compare statement. I'll mod this & post the new version.

    I have seen the errors that you posted when permissions on the target box wouldn't allow WMI remote starts. For example, I can run this agains two 2003 servers on my system. But, when I run it against an XP box I get the errors that you posted. I'll look into the XP policies & see what I can find.


    Last edited by cactsbob; August 16, 2006, 08:31 AM.


      It looks like the ActiveX components have to be explicitly allowed under XP. I found this url with some information.


        I recently moved Homeseer to a new box. I got the above errors until I ran the process watcher script under a userid that had permissions to run remote wmi.

        I am running HS as a service. So, I changed the service to run under a userid that had remote wmi permissions & everything worked ok.


          Commenting out lines in this script

          Hi Bob,

          I recently set up this script to keep an eye on my VWS program. It works great, Thanks!

          I did run into a problem when I tried to comment out some of the process information that is displayed in the HSLog if "Found = True" (just trying to clean up the log a bit). The following lines can be commented out by using a single quote mark:
              hs.WriteLog("PROC", "Process: " & objProcess.Name)
              hs.WriteLog("PROC.STATUS", "Process ID: " & objProcess.ProcessID)
              hs.WriteLog("PROC.STATUS", "Thread Count: " & objProcess.ThreadCount)
          However, when I get to the lines that contain the underscore symbol preceding the variable name:
              hs.WriteLog("PROC.STATUS", "Page File Size: " _
               & objProcess.PageFileUsage)
              hs.WriteLog("PROC.STATUS", "Page Faults: " _
               & objProcess.PageFaults)
              hs.WriteLog("PROC.STATUS", "Working Set Size: " _
               & objProcess.WorkingSetSize)
          I receive an error from HS of
          7/10/2007 12:18:26 PM ~!~Error~!~Script compile error: Syntax error.on line 93
          7/10/2007 12:18:26 PM ~!~SCR~!~Option Strict Offimports Schedulerimports SystemPublic Module scriptcode3#Region "Automatically generated code, do not modify"'Automatically generated code, do not modify'

          Why am I not able to comment out the lines that have the underscore symbol in them? I am able to delete these lines from the script, and keep the process information from showing in the HSLog, with no error message. However, as a newbie to vbscripting, I would like to understand why I get the error message.

          Last edited by Jerry S; July 10, 2007, 12:25 PM. Reason: Added additional error message


            Looking at this the above code looks correct.

            What is on line 93 and what is the full error message (the whole of the second line in the log error)?

            The lines with the underscore symbol are continued statements. You have to delete the line and any further continuation lines (that end in the continuation character of underscore) below them, including the last one without a continuation symbol, to avoid a syntax error.


              Hi Fuego,

              Thanks for the nudge in the right direction. I removed the underscores from the statements, along with the spaces and tabs that followed the underscores, tried to comment out the lines with a single quote, and all works well.

              I'll do a little learning on the website you mentioned, and hopefully have less of these beginner questions as time passes.

              Thanks again,