Powershell export not bring é through correctly.

Alex
Alex used Ask the Experts™
on
Morning,

When I run an export from active directory via powershell, it doesn't bring in the é letters or anything, how can I force it to do that rather than the  Eléctrico that it's giving me. Essentially it should be Eléctricos

Thanks,
Alex
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Most Valuable Expert 2018
Distinguished Expert 2018
Commented:
Use Unicode as Encoding for Export-Csv:
Get-AD... | Select-Object -Property ... | Export-Csv -NoTypeInformation -Encoding Unicode -Path C:\Temp\export.csv

Open in new window

AlexSenior Infrastructure Analyst

Author

Commented:
You wonderful, wonderful person!!!!

I googled that for AGES and couldn't find anything, I thought I needed some sort of language pack :S

Thanks OBdA
Top Expert 2014

Commented:
Sidenote - UTF8 encoding could also work for your needs.  Not really important unless there's restrictions imposed by other apps that may consume the text output.
AlexSenior Infrastructure Analyst

Author

Commented:
Not really, I just need it to import a LOT of data straight into active directory. We're doing a dump of oracle to an excel sheet then importing specific details into AD using an employee number as a unique identifier for the oracle active directory sync

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial