Register
: :
Login
Home
News
Forums
Scripts
User Groups
Resources
About
Forums
Search
Members
Unanswered
Active Topics
Forums
>
Using PowerShell
>
General PowerShell
Remove first line in .csv file
Last Post 11 Aug 2011 10:24 AM by
mr_evans2u
. 2 Replies.
Sort:
Oldest First
Most Recent First
Prev
Next
You are not authorized to post a reply.
Author
Messages
mr_evans2u
New Member
Posts:32
11 Aug 2011 08:16 AM
I am writing to a .csv file but when I pull it up the first row has:
#TYPE selected.Quest.ActivRoles.ArsPowerShellSnapIn.Data.ArsUserobject
I don't want this in there, how can I delete this row and still keep all my columns?
Here is the code I'm using:
Get-QADUser -organizationalUnit $OU -IncludedProperties extensionAttribute4 -InactiveFor 90 |Select-Object DisplayName,email,extensionAttribute4 |export-csv $OUusers
halr9000
PowerShell MVP, Site Admin
Advanced Member
Posts:565
11 Aug 2011 08:55 AM
Use the -NoTypeInformation parameter with export-csv.
Community Director,
PowerShellCommunity.org
Co-host,
PowerScripting Podcast
Author,
TechProsaic
mr_evans2u
New Member
Posts:32
11 Aug 2011 10:24 AM
thanks halr9000 that worked
You are not authorized to post a reply.
Using PowerShell
--General PowerShell
--Active Directory
--Exchange Server
--Lync Server
--SharePoint
--SQL Server
--System Center
--Non-Microsoft Products
--Books, Tools, and Videos
--Working with .NET
--Peer Review
--Testing, Testing...
PowerShell Development
--Cmdlet Development
--PSDrive Provider Development
--Hosting the Shell
Looking Ahead
--Using PowerShell v2.0
--Developing for PowerShell v2.0
PowerShellCommunity.org
--Community Announcements and Assistance
--Completely Unrelated
--User Groups
--Community Business
----Suggestion Box
Forums
>
Using PowerShell
>
General PowerShell
Active Forums 4.3
Sponsored by Quest Software • SAPIEN Technologies • Compellent • Microsoft Windows Server 2008 R2