How do I get powershell to return data without any formating

Posted on 2009-04-16
Last Modified: 2012-05-06
Hello Experts,

I'm new to PowerShell.  I'm using PowerShell 1.0 and have downloaded the Active Directory commandlets from  I want to get a list of users in a certain department.  I use the following from the Quest shell.

get-qaduser -department GIS | select-object Name

This returns the information in a nice formatted manner.  There is a column with a column header of Name.  I would like the data to be returned without the preconfigured formating and without the column header.  How would I do that?
Question by:ndalmolin_13
    LVL 1

    Author Comment

    If I run the following command:    (get-service spooler).status
    the only thing returned is: running.

     I have tried (get-qaduser -department GIS).name   and I get nothing.  Any help would be appreciated.

    LVL 70

    Accepted Solution


    Get-QADUser -Department GIS | %{ $_.Name }

    % is ForEach-Object, a loop through every returned item. $_.Name just echoes the Name property (of the object passed in the pipeline). That gives you a simple, unformatted, list.

    LVL 70

    Expert Comment

    by:Chris Dent

    > I have tried (get-qaduser -department GIS).name

    That only works when there's only a single object in the list. You have more than one so it failed, that's where the loop above comes in.

    LVL 1

    Author Closing Comment

    This is exactly what I needed.  Thanks for your quick response.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    This script checks a path to see if a folder exists. If the folder does exist you will get output "The folder has previously been created. No action taken" If not it will create the folder. Then adds one user modify permission to the folder. It …
    How to sign a powershell script so you can prevent tampering, and only allow users to run authorised Powershell scripts
    The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
    In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now