And here my solution:
$List = @()
$Updates_Pretest = $WSUS.GetUpdates() | select -First 10
if ($Updates_Pretest.count -gt 0)
{
$List = $Updates_Pretest | ForEach {
[pscustomobject]@{
ID = $_.Id.UpdateId.Guid
Ankunftsdatum = (Get-Date -Format "MM.dd.yyyy")
UpdateTitle = $_.title
}}
}
$List | Export-Clixml -Path ("c:\" + "Test.xml")