Monday, January 19, 2009

when XML denies CSV and HTM

to get the ServiceController objects for all of the services that are running in their own processes, then export this information to a CSV file

PS R:\> get-service
| where { $_.serviceType -eq "Win32OwnProcess" }
| export-csv -notype ./edit3.csv

or,

PS R:> get-service | where { $_.serviceType -eq "Win32OwnProcess" } | export-csv -notype ./edit3.csv


or,

PS R:\> get-service
| where { $_.serviceType -eq "Win32OwnProcess" }
| export-csv -notype ./edit3.htm <--- not applicable for .xml


` edit3.csv ` contains delimited (comma-separted) text.

No comments:

Post a Comment