feat: Add newlines to status text for file listing

This commit is contained in:
Bobby Abellana (aider) 2025-02-21 09:46:16 -08:00
parent c70add19f6
commit 6bda577ba3

View File

@ -258,8 +258,12 @@ function List-XlsFiles {
$fileList = Get-XlsFilesRecursive -DriveId $drive.Id -DriveItemId $root.Id $fileList = Get-XlsFilesRecursive -DriveId $drive.Id -DriveItemId $root.Id
} }
if ($fileList.Count -gt 0) { if ($fileList.Count -gt 0) {
$script:txtStatus.Text += "Saving file list...`n" $script:txtStatus.Text += "Saving file list...`n"
# Display each file on a new line
$fileList | ForEach-Object {
$script:txtStatus.Text += "$($_.OriginalFileName)`n"
}
$fileList | ConvertTo-Json | Out-File "$env:TEMP\FileList.json" $fileList | ConvertTo-Json | Out-File "$env:TEMP\FileList.json"
$script:txtStatus.Text += "Found $($fileList.Count) XLS files`n" $script:txtStatus.Text += "Found $($fileList.Count) XLS files`n"
} else { } else {