Would like to convert a CSV while retaining leading zeros #1313
Replies: 3 comments 1 reply
-
@David-Globe-Electric thank you! May not have that example here is a way: Import-Csv .\salesData.csv | Export-Excel .\salesData.xlsx -NoNumberConversion -Show |
Beta Was this translation helpful? Give feedback.
-
Sorry, you need to specify the name of the property to do the |
Beta Was this translation helpful? Give feedback.
-
Thank you so much! This is so useful! For future readers, I simply specified the column names separated by commas: Import-Csv .\FiletoConvert.csv | Export-Excel .\ConvertedFile.xlsx -NoNumberConversion columnx, columny -Show Columnx and y are simply the headers of the columns in the CSV file. |
Beta Was this translation helpful? Give feedback.
-
I love your PS module!
I am having trouble finding examples of how to take an existing CSV file and converting it to Excel using your tool.
An added bonus is retaining leading zeros, which AFAIK, is possible using the -NoNumberConversion switch.
I watched the youtube playlist and rifled through the examples. Maybe I missed it :(
Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions