Architecting, installing and maintaining your SAS environment

SMC - Scheduled Jobs - VBS error

Reply
Contributor
Posts: 31

SMC - Scheduled Jobs - VBS error

Hi all

 

We are in the final stages of installing SAS on a new server and are now rescheduling all of our jobs.  For some reason, I am getting the below error when I call a VBS file using cscript and pipe (example.. 'cscript "\\fileserver1\Users\Durrant\Reports\Weekly Onboarding Report\New Customer Purchases\NCP.vbs"'.  I only get this error when I schedule the job.  If I run directly in base SAS on the server or EG on a end user computer, it works fine.   The file and path both exist.  It's not being used by another program and I am not saving it as the same name.

 

In google and forum searches, I found serveral suggestions to confirm that xcmd is inacted in the Server.  I have confirmed that it is active (not the default noxcmnd).  Any other suggestions for what might be causing the error in scheduled jobs?

 

Thanks!

 

"\\fileserver1\Users\Durrant\Reports\Weekly Onboarding Report\New Customer Purchases\NCP.vbs(30, 1) Microsoft Excel: Microsoft Excel
cannot access the file '\\fileserver1\Users\Durrant\Reports\Weekly O
boarding Report\New Customer Purchases\Archive\Export.xlsx'. There are several possible reasons:

 The file name or path does not exist.
 The file is being used by another program.
 The workbook you are trying to save has the same name as a currently open workbook."

 

 

Occasional Contributor
Posts: 18

Re: SMC - Scheduled Jobs - VBS error

Posted in reply to stuart_snap

Please try the following. It may or may not work.

1.Double Quote the below path and run the job.

\\fileserver1\Users\Durrant\Reports\Weekly O
boarding Report\New Customer Purchases\Archive\Export.xlsx'. 

 

2. Create sample vbs file to copy the below file from location to another and check if you get an access error. If yes, we can make sure that, the userid(execution userid ) does not have access to below location or a file.

\\fileserver1\Users\Durrant\Reports\Weekly O
boarding Report\New Customer Purchases\Archive\Export.xlsx'. 

 

 

Ask a Question
Discussion stats
  • 1 reply
  • 164 views
  • 0 likes
  • 2 in conversation