not sure why it posted it like that.
directory path
$csvtemp = ".\xxxx.csv"
$UniquexxList = Import-Csv -Path $xxxx, 'name', "name", 'name', 'name', 'name' | group -AsHashTable -Property
$x = $($xx."name")
$y = $($x)
$FileName = $(Get-Date -Format yyyyMMdd)
Try {
#Assign variables/path for Open object edit
$xl = $xxData.$($x) | Sort -Descending | Sort -Descending | Export-Csv -Path ""$xxx\$xReport.xlsx" -PassThru -NoNumberConversion
}
Catch {}