Skip to Content
author's profile photo Former Member
Former Member

CRSXI: Problem Executing .vbs

Simple .vbs (which has no problem running directly when clicked)...but in CRS XI


Server Used: r2crny01.programjobserver

Error Message: An unknown COM error has occurred while trying to run the script.


Not familiar with COM issues - and this is so vague. Can anyone help?


Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Posted on Aug 12, 2008 at 09:57 PM

    What exactly is the script trying to do?

    I assume from your description that you are trying to schedule the vbs script through CR Server. The error could be a permissions error in that the user that the program job server runs under doesn't have access to some needed resource. I would suggest adding some logging to the script (just save to a disk file) so that you can find out the exact line on which the error occurs.


    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Thanks for the help. The last step of the vbs does write to a file - so I do see the error.

      The whole vbs is:

      Dim WSHShell, filesys, logfile

      Set WSHShell = WScript.CreateObject("WScript.Shell")

      Set filesys = CreateObject("Scripting.FileSystemObject") "C:\Oracle\product\10.1.0\Client_1\BIN\sqlplus id/pw@server @D:\RCRA\UniverseUpdate\V3-Synonyms.txt", 0, TRUE "C:\Oracle\product\10.1.0\Client_1\BIN\sqlplus id/pw@server @D:\FOIA\CreateR2HandlerExportTable.txt", 0, TRUE

      Set logfile= filesys.CreateTextFile("D:\FOIA\R2HandlerExportTable.txt", True)

      logfile.WriteLine "HandlerExportTable Created."


      Set WSHShell=Nothing


      This used Oracle sqlplus to execute a synonyms file and then some other SQL via a Shell. What comes out if I run the .vbs from inside a bat (and load the bat as an executable in CRS) is:

      D:\FOIA\FOIAStaticSQLTable.vbs(5, 1) (null): The system cannot find the file specified.

      (5,1) = Row 5 refers the first row the appears. The paths are correct, so it just can't seem to find the WSHShell variable? Again, not sure how it can't, the script run fine, on the same server if clicked on directly.

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.