Hello @Fattah N ,
There are several options you can consider to save the CSV file when running a PowerShell script with Microsoft Endpoint Manager and Intune. Here are a few examples:
Save the CSV file to a local folder on the device: You can use the "Out-File" cmdlet in PowerShell to save the CSV file to a local folder on the device. For example:
Import-Csv C:\path\to\input.csv | Out-File C:\path\to\output.csv
Save the CSV file to a network share: You can use the "Out-File" cmdlet in PowerShell to save the CSV file to a network share. For example:
Import-Csv C:\path\to\input.csv | Out-File \server\share\output.csv
Save the CSV file to a cloud storage service: You can use the "Out-File" cmdlet in PowerShell to save the CSV file to a cloud storage service like Azure Blob Storage or Amazon S3. For example:
Import-Csv C:\path\to\input.csv | Out-File https://myaccount.blob.core.windows.net/mycontainer/output.csv
All the best,