pscustomobject

How to get Select-Object to return a raw type (e.g. String) rather than PSCustomObject?

The following code gives me an array of PSCustomObjects, how can I get it to return an array of Strings? $files = Get-ChildItem $directory -Recurse | Select-Object FullName | Where-Object {!($_.psiscontainer)} (As a secondary question, what's the psiscontainer part for? I copied that from an example online) Post-Accept Edit: Two grea...

Creating custom objects and using the output

I'm using the following to read one line from a whole load of text files and then summarize that information into one file. $computers = Get-content computers.txt $users = users.csv $header = 'Computer','User','Date','Time' Foreach ($computer in $computers) { $file = $computer +'.txt' $a = import-csv $file -Header $header | Select -...