Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 230613

Re: Append output file with vCenter name and date

$
0
0

getting the below error when I am executing the script

 

Exception calling "SaveAs" with "1" argument(s): "The file could not be accessed

Make sure the specified folder exists.

Make sure the folder that contains the file is not read-only.

Make sure the file name does not contain any of the following characters:  <  >

Make sure the file/path name doesn't contain more than 218 characters."

At C:\Aravind\Scripts\Excel-Report.ps1:241 char:1

+ $workbook.SaveAs("C:\Aravind\Scripts\$vcenter-$date.xls")

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException

    + FullyQualifiedErrorId : ComMethodTargetInvocation


Viewing all articles
Browse latest Browse all 230613

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>