Hi Luc ,
can you please check the following .i want to utilize $date in out-file command so that name of the output file has date componenet in it,
can you please suggest what is the right way of doing it.
$path='C:\Users\user1\Desktop\scriptfolder'
$date=get-date
get-cluster|out-file -filepath $path\$date.txt
When you use double quotes, you can use variable/expression substitution in a string.
Something like this for example
Get-Cluster| Out-File -FilePath $path
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
When you use double quotes, you can use variable/expression substitution in a string.
Something like this for example
Get-Cluster| Out-File -FilePath $path
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
thanks.