Hi Dominique DUCHEMIN,
Please refer to the below script by the PowerShell to see whether this issue will be resolve or not:
# Get OS info
$OsInfo = Get-CimInstance -ClassName Win32_OperatingSystem
Get-Hotfix | # Get HotFixes
Sort-Object -Property InstalledOnfunction | # Sort them
Select-Object -Property @( # Select required fields
# Add Caption property from $OsInfo variable
@{
Name = 'Caption'
Expression = {$OsInfo.Caption}
}
# Add CSDVersion property from $OsInfo variable
@{
Name = 'CSDVersion'
Expression = {$OsInfo.CSDVersion}
}
# Add ServicePackMajorVersion property from $OsInfo variable
@{
Name = 'ServicePackMajorVersion'
Expression = {$OsInfo.ServicePackMajorVersion}
}
# Add BuildNumber property from $OsInfo variable
@{
Name = 'BuildNumber'
Expression = {$OsInfo.BuildNumber}
}
# Add other properties from original HotFix object
'CSName'
'HotfixID'
'Description'
'InstalledBy'
'InstalledOn'
) | Export-Csv -NoTypeInformation -Path 'c:\Windows\Temp\win-patch.csv'
Reference link:
https://stackoverflow.com/questions/48488767/save-the-powershells-output-in-a-csv-file
Hope the above will be helpful. Please keep us in touch if there are any updates of the case.
Regards,
Rita
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.