I did, the defined variables are below
$script:vm_Found_YES =@()
$vm_Found_NO = @()
$isVRAmanaged = @()
$targetList = get-content $Script:file
$count = $targetList | Measure-Object -Line
$i = 1
$dir = $Script:directory
$vm_Found_YES_ReportPath = $Script:directory + "\" + $script:appName + "-FoundReport-" + (Get-Date -Format yyyy-MMM-dd-HHmm) + ".xlsx"
$vm_Found_NO_ReportPath = $Script:directory + "\" + $script:appName + "-NotFoundReport-" + (Get-Date -Format yyyy-MMM-dd-HHmm) + ".xlsx"
$isVRAmanaged_ReportPath = $Script:directory + "\" + $script:appName + "-isVRAManaged-" + (Get-Date -Format yyyy-MMM-dd-HHmm) + ".xlsx"
As mentioned though, this works for 99% of my VCSA's.
it's just one where it doesn't work as expected. i don't think it's a script issue but i've no idea why the hash table remains empty for that one VCSA.