Quantcast
Channel: The Official Scripting Guys Forum! forum
Viewing all articles
Browse latest Browse all 15028

Powertools - Export excel with formatted column width and cell color

$
0
0

I'm using the powertools to export the data from a datatable. Export-OpenXmlSpreadshet to export the data to Excel 2007 format (xlsx).  

get-process | export-OpenXmlSpreadsheet "c:\Files\text1.xlsx"

I need to set the width of the column using a template file (or) set the column width to autofit (or) set the column width to a specific value. 

I saw the cmdlet "Set-OpenXmlSpreadSheetColumnWidth" in powertools, however i couldn't find out how to use it. Also, I need to know about "Set-OpenXmlSpreadSheetCellStyle" cmdlet. 

Can you please help me to export rich formatted Excel Sheet using PowerShell + Powertools? 



Viewing all articles
Browse latest Browse all 15028

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>