I am learning PowerShell. During my experiments I used the following command:
PS C:\Windows\system32> gci -path C:\windows\ | Where-Object{$_.LastWriteTime -
gt "01-04-2011"} | Format-List -property Fullname | ConvertTo-Html | out-file E:
\PowerShell\Out.html
I expected the output like the one displayed in the console (like:FullName:C:\Windows...). But when I open the Out.html it has some strange things like:
ClassId2e4f51ef21dd47e pageHeaderEntry pageFooterEntry autosizeInfo shapeInfo groupingEntry
What am I missing here?
Format-TableorSelect-Objectin place ofFormat-List? Or you should appendConvertTo-Htmldirectly after theWhere-ObjectFormat-Tabletoo..didn't make any difference.ConvertTo-Htmldirectly afterwhere-objectFormat-ListI should useSelect-Object. If you can post that as an answer I will accept it.