mirror of
https://github.com/dfinke/ImportExcel.git
synced 2025-12-06 00:23:20 +00:00
added back badges
This commit is contained in:
60
README.md
60
README.md
@@ -1,3 +1,17 @@
|
||||
<p align="center">
|
||||
<a href="https://ci.appveyor.com/project/dfinke/importexcel/branch/master"><img src="https://ci.appveyor.com/api/projects/status/21hko6eqtpccrkba/branch/master?svg=true"></a>
|
||||
<a href="https://dougfinke.visualstudio.com/ImportExcel/_build/latest?definitionId=8"><img src="https://dougfinke.visualstudio.com/ImportExcel/_apis/build/status/ImportExcel-CI"></a>
|
||||
</p>
|
||||
|
||||
<p align="center">
|
||||
<a href="./LICENSE.txt"><img
|
||||
src="https://img.shields.io/badge/License-Apache%202.0-blue.svg"></a>
|
||||
<a href="https://www.powershellgallery.com/packages/ImportExcel"><img
|
||||
src="https://img.shields.io/powershellgallery/dt/ImportExcel.svg"></a>
|
||||
<a href="https://www.powershellgallery.com/packages/ImportExcel"><img
|
||||
src="https://img.shields.io/powershellgallery/v/ImportExcel.svg"></a>
|
||||
</p>
|
||||
|
||||
PowerShell Import-Excel
|
||||
-
|
||||
|
||||
@@ -7,7 +21,7 @@ This PowerShell Module allows you to read and write Excel files without installi
|
||||
|
||||

|
||||
|
||||
# How to Vidoes
|
||||
# How to Videos
|
||||
* [PowerShell Excel Module - ImportExcel](https://www.youtube.com/watch?v=U3Ne_yX4tYo&list=PL5uoqS92stXioZw-u-ze_NtvSo0k0K0kq)
|
||||
|
||||
Installation
|
||||
@@ -32,16 +46,16 @@ iex (new-object System.Net.WebClient).DownloadString('https://raw.github.com/dfi
|
||||
```
|
||||
|
||||
# What's new to 18th July 18
|
||||
- Moved chart creation into its own function (Add-Excel chart) within Export-Excel.ps1. Renamed New-Excelchart to New-ExcelChartDefinition to make it clearer that it is not making anything in the workbook (but for compatiblity put an alias of New-ExcelChart in so existing code does not break). Found that -Header does nothing, so it isn't Add-Excel chart and there is a message that does nothing in New-ExcelChartDefinition .
|
||||
- Moved chart creation into its own function (Add-Excel chart) within Export-Excel.ps1. Renamed New-Excelchart to New-ExcelChartDefinition to make it clearer that it is not making anything in the workbook (but for compatibility put an alias of New-ExcelChart in so existing code does not break). Found that -Header does nothing, so it isn't Add-Excel chart and there is a message that does nothing in New-ExcelChartDefinition .
|
||||
- Added -BarChart -ColumnChart -LineChart -PieChart parameters to Export-Excel for quick charts without giving a full chart definition.
|
||||
- Added parameters for managing chart Axes and legend
|
||||
- Added some chart tests to Export-Excel.tests.ps1. (but tests & examples for quick charts , axes or legends still on the to do list )
|
||||
- Fixed some bad code which had been checked-in in-error and caused adding charts to break. (This was not seen outside Github #377)
|
||||
- Added "Revese" parameter to Add-ConditionalFormatting ; and added -PassThru to make it easier to modify details of conditional formating rules after creation (#396)
|
||||
- Fixed some bad code which had been checked-in in-error and caused adding charts to break. (This was not seen outside GitHub #377)
|
||||
- Added "Reverse" parameter to Add-ConditionalFormatting ; and added -PassThru to make it easier to modify details of conditional formatting rules after creation (#396)
|
||||
- Refactored ConditionalFormatting code in Export excel to use Add-ConditionalFormatting.
|
||||
- Rewrote Copy-ExcelWorksheet to use copy functionality rather than import | export (395)
|
||||
- Found sorts could be inconsitent in Merge-MultipleWorksheet, so now sort on more columns.
|
||||
- Fixed a bug introduced into Compare-Worksheet by the change descibed in the June changes below, this meant the font color was only being set in one sheet, when a row was changed. Also found that the PowerShell ISE and shell return Compare-Object resuls in different sequences which broke some tests. Applied a sort to ensure things are in a predictable order. (#375)
|
||||
- Found sorts could be inconsistent in Merge-MultipleWorksheet, so now sort on more columns.
|
||||
- Fixed a bug introduced into Compare-Worksheet by the change described in the June changes below, this meant the font color was only being set in one sheet, when a row was changed. Also found that the PowerShell ISE and shell return Compare-Object results in different sequences which broke some tests. Applied a sort to ensure things are in a predictable order. (#375)
|
||||
- Removed (2) calls to Get-ExcelColumnName (Removed and then restored function itself)
|
||||
- Fixed an issue in Export-Excel where formulas were inserted as strings if "NoNumberConversion" is applied (#374), and made sure formatting is applied to formula cells
|
||||
- Fixed an issue with parameter sets in Export-Excel not being determined correctly in some cases (I think this had been resolved before and might have regressed)
|
||||
@@ -51,15 +65,15 @@ iex (new-object System.Net.WebClient).DownloadString('https://raw.github.com/dfi
|
||||
- Added more of the Parameters from Export-Excel to Send-SQLDataToExcel, send just calls export-excel with these parameters...
|
||||
- Added support for passing a System.Data.DataTable directly to Send-SQLDataToExcel
|
||||
- Fixed a bug in Merge-MultipleSheets where if the key was "name", columns like "displayName" would not be processed correctly, nor would names like "something_ROW". Added tests for Compare, Merge and Join Worksheet
|
||||
- Add-Worksheet , fixed a regression with move-after (#392), changed way default worksheet name is decided, so if none is specified, and an existing worksheet is copied (see June additions) and the name doesn't already exist, the orginal sheet name will be kept. (#393) If no name is given an a blank sheet is created, then it will be named sheetX where X is the number of the sheet (so if you have sheets FOO and BAR the new sheet will be Sheet3).
|
||||
- Add-Worksheet , fixed a regression with move-after (#392), changed way default worksheet name is decided, so if none is specified, and an existing worksheet is copied (see June additions) and the name doesn't already exist, the original sheet name will be kept. (#393) If no name is given an a blank sheet is created, then it will be named sheetX where X is the number of the sheet (so if you have sheets FOO and BAR the new sheet will be Sheet3).
|
||||
|
||||
# New in June 18
|
||||
- New commands - Diff , Merge and Join
|
||||
- `Compare-Worksheet` (introduced in 5.0) uses the built in `Compare-object` command, to output a command-line DIFF and/or colour the worksheet to show differences. For example, if my sheets are Windows services the *extra* rows or rows where the startup status has changed get highlighted
|
||||
- `Compare-Worksheet` (introduced in 5.0) uses the built in `Compare-object` command, to output a command-line DIFF and/or color the worksheet to show differences. For example, if my sheets are Windows services the *extra* rows or rows where the startup status has changed get highlighted
|
||||
- `Merge-Worksheet` (also introduced in 5.0) joins two lumps, side by highlighting the differences. So now I can have server A's services and Server Bs Services on the same page. I figured out a way to do multiple sheets. So I can have Server A,B,C,D on one page :-) that is `Merge-MultpleSheets`
|
||||
For this release I've fixed heaven only knows how many typos and proof reading errors in the help for these two, the only code change is to fix a bug if two worksheets have different names, are in different files and the Comparison sends the delta in the second back before the one in first, then highlighting changed properties could throw an error. Correcting the spelling of Merge-MultipleSheets is potentially a breaking change (and it is still plural!)
|
||||
also fixed a bug in compare worksheet where color might not be applied correctly when the worksheets came from different files and had different name.
|
||||
- `Join-Worksheet` is **new** for ths release. At it's simplest it copies all the data in Worksheet A to the end of Worksheet B
|
||||
- `Join-Worksheet` is **new** for this release. At it's simplest it copies all the data in Worksheet A to the end of Worksheet B
|
||||
- Add-Worksheet
|
||||
- I have moved this from ImportExcel.psm1 to ExportExcel.ps1 and it now can move a new worksheet to the right place, and can copy an existing worksheet (from the same or a different workbook) to a new one, and I set the Set return-type to aid intellisense
|
||||
- New-PivotTableDefinition
|
||||
@@ -71,9 +85,9 @@ iex (new-object System.Net.WebClient).DownloadString('https://raw.github.com/dfi
|
||||
1. I "flattened out" small "called-once" functions , add-title, convert-toNumber and Stop-ExcelProcess.
|
||||
2. It now uses Add-Worksheet, Open-ExcelPackage and Add-ConditionalFormat instead of duplicating their functionality.
|
||||
3. I've moved the PivotTable functionality (which was doubled up) out to a new function "Add-PivotTable" which supports some extra parameters PivotFilter and PivotDataToColumn, ChartHeight/width ChartRow/Column, ChartRow/ColumnPixelOffsets.
|
||||
4. I've made the try{} catch{} blocks cover smaller blocks of code to give a better idea where a failure happend, some of these now Warn instead of throwing - I'd rather save the data with warnings than throw it away because we can't add a chart. Along with this I've added some extra write-verbose messages
|
||||
4. I've made the try{} catch{} blocks cover smaller blocks of code to give a better idea where a failure happened, some of these now Warn instead of throwing - I'd rather save the data with warnings than throw it away because we can't add a chart. Along with this I've added some extra write-verbose messages
|
||||
- Bad column-names specified for Pivots now generate warnings instead of throwing.
|
||||
- Fixed issues when pivottables / charts already exist and an export tries to create them again.
|
||||
- Fixed issues when pivot tables / charts already exist and an export tries to create them again.
|
||||
- Fixed issue where AutoNamedRange, NamedRange, and TableName do not work when appending to a sheet which already contains the range(s) / table
|
||||
- Fixed issue where AutoNamedRange may try to create ranges with an illegal name.
|
||||
- Added check for illegal characters in RangeName or Table Name (replace them with "_"), changed tablename validation to allow spaces and applied same validation to RangeName
|
||||
@@ -85,11 +99,11 @@ iex (new-object System.Net.WebClient).DownloadString('https://raw.github.com/dfi
|
||||
- Added "NoScriptOrAliasProperties" "DisplayPropertySet" switches (names subject to change) - combined with ExcludeProperty these are a quick way to reduce the data exported (and speed things up)
|
||||
- Added PivotTableName Switch (in line with 5.0.1 release)
|
||||
- Add-CellValue now understands URI item properties. If a property is of type URI it is created as a hyperlink to speed up Add-CellValue
|
||||
- Commented out the write verbose statements even if verbose is silenced they cause a significiant performance impact and if it's on they will cause a flood of messages.
|
||||
- Commented out the write verbose statements even if verbose is silenced they cause a significant performance impact and if it's on they will cause a flood of messages.
|
||||
- Re-ordered the choices in the switch and added an option to say "If it is numeric already post it as is"
|
||||
- Added an option to only set the number format if doesn't match the default for the sheet.
|
||||
- Export-Excel Pester Tests
|
||||
- I have converted examples 1-9, 11 and 13 from Export-Excel help into tests and have added some additional tests, and extra parameters to the example command to ge better test coverage. The test so far has 184 "should" conditions grouped as 58 "IT" statements; but is still a work in progress.
|
||||
- I have converted examples 1-9, 11 and 13 from Export-Excel help into tests and have added some additional tests, and extra parameters to the example command to get better test coverage. The test so far has 184 "should" conditions grouped as 58 "IT" statements; but is still a work in progress.
|
||||
- Compare-Worksheet pester tests
|
||||
|
||||
---
|
||||
@@ -103,7 +117,7 @@ Thanks to the community yet again
|
||||
- [ili101](https://github.com/ili101) for fixes and features
|
||||
- Removed `[PSPlot]` as OutputType. Fixes it throwing an error
|
||||
- [Nasir Zubair](https://github.com/nzubair) added `ConvertEmptyStringsToNull` to the function `ConvertFrom-ExcelToSQLInsert`
|
||||
- If specified, cells without any data are replaced with NULL, instead of an empty string. This is to address behviors in certain DBMS where an empty string is insert as 0 for INT column, instead of a NULL value.
|
||||
- If specified, cells without any data are replaced with NULL, instead of an empty string. This is to address behaviors in certain DBMS where an empty string is insert as 0 for INT column, instead of a NULL value.
|
||||
|
||||
|
||||
#### 4/10/2018
|
||||
@@ -115,7 +129,7 @@ Super helpful!
|
||||
|
||||
#### 3/31/2018
|
||||
- Updated `Set-Format`
|
||||
* Added parameters to set borders for cells, including top, bottm, left and right
|
||||
* Added parameters to set borders for cells, including top, bottom, left and right
|
||||
* Added parameters to set `value` and `formula`
|
||||
|
||||
```powershell
|
||||
@@ -158,7 +172,7 @@ North,A1,Grape,140,2.5
|
||||
* Add example to set the background color of a column
|
||||
* Supports excluding Row Grand Totals for PivotTables
|
||||
* Allow xlsm files to be read
|
||||
* Fix `Set-Column.ps1`, `Set-Row.ps1`, `SetFormat.ps1`, `formatting.ps1` **$falsee** and **$BorderRound**
|
||||
* Fix `Set-Column.ps1`, `Set-Row.ps1`, `SetFormat.ps1`, `formatting.ps1` **$false** and **$BorderRound**
|
||||
#### 1/1/2018
|
||||
* Added switch `[Switch]$NoTotalsInPivot`. Allows hiding of the row totals in the pivot table.
|
||||
Thanks you to [jameseholt](https://github.com/jameseholt) for the request.
|
||||
@@ -184,7 +198,7 @@ More great additions and thanks to [James O'Neill](https://twitter.com/jamesonei
|
||||
* Corrected a typo PivotTableName was PivtoTableName in definition of New-PivotTableDefinition
|
||||
* Add-ConditionalFormat and Set-Format added to the parameters so each has the choice of working more like the other.
|
||||
* Added Set-Row and Set-Column - fill a formula down or across.
|
||||
* Added Send-SQLDataToExcel. Insert a rowset and then call Export-Excel for ranges, charts, pivots etc
|
||||
* Added Send-SQLDataToExcel. Insert a rowset and then call Export-Excel for ranges, charts, pivots etc.
|
||||
|
||||
#### 10/30/2017
|
||||
Huge thanks to [James O'Neill](https://twitter.com/jamesoneill). PowerShell aficionado. He always brings a flare when working with PowerShell. This is no exception.
|
||||
@@ -202,8 +216,8 @@ Huge thanks to [James O'Neill](https://twitter.com/jamesoneill). PowerShell afic
|
||||
(Check out the examples `help Export-Excel -Examples`)
|
||||
|
||||
* New function `Export-Charts` (requires Excel to be installed) - Export Excel charts out as JPG files
|
||||
* New function `Add-ConditionalFormatting` Adds contitional formatting to worksheet
|
||||
* New function `Set-Format` Applies Number, font, alignment and colour formatting to a range of Excel Cells
|
||||
* New function `Add-ConditionalFormatting` Adds conditional formatting to worksheet
|
||||
* New function `Set-Format` Applies Number, font, alignment and color formatting to a range of Excel Cells
|
||||
* `ColorCompletion` an argument completer for `Colors` for params across functions
|
||||
|
||||
I also worked out the parameters so you can do this, which is the same as passing `-Now`. It creates an Excel file name for you, does an auto fit and sets up filters.
|
||||
@@ -213,7 +227,7 @@ I also worked out the parameters so you can do this, which is the same as passin
|
||||
#### 10/13/2017
|
||||
Added `New-PivotTableDefinition`. You can create and wire up a PivotTable to a WorkSheet. You can also create as many PivotTable Worksheets to point a one Worksheet. Or, you create many Worksheets and many corresponding PivotTable Worksheets.
|
||||
|
||||
Here you can create a WorkSheet with the data from `Get-Service`. Then create four PivotTables, pointing to the data each pivoting on a differnt dimension and showing a differnet chart
|
||||
Here you can create a WorkSheet with the data from `Get-Service`. Then create four PivotTables, pointing to the data each pivoting on a different dimension and showing a different chart
|
||||
|
||||
```powershell
|
||||
$base = @{
|
||||
@@ -395,7 +409,7 @@ Get-Process |
|
||||

|
||||
|
||||
#### 9/28/2016
|
||||
[Fixed](https://github.com/dfinke/ImportExcel/pull/126) PowerShell 3.0 compatibility. Thanks to [headsphere](https://github.com/headsphere). He used `$obj.PSObject.Methods[$target]` snytax to make it backward compatible. PS v4.0 and later allow `$obj.$target`.
|
||||
[Fixed](https://github.com/dfinke/ImportExcel/pull/126) PowerShell 3.0 compatibility. Thanks to [headsphere](https://github.com/headsphere). He used `$obj.PSObject.Methods[$target]` syntax to make it backward compatible. PS v4.0 and later allow `$obj.$target`.
|
||||
|
||||
Thank you to [xelsirko](https://github.com/xelsirko) for fixing - *Import-module importexcel gives version warning if started inside background job*
|
||||
|
||||
@@ -431,7 +445,7 @@ Thanks Attila.
|
||||
#### 4/30/2016
|
||||
Huge thank you to [Willie Möller](https://github.com/W1M0R)
|
||||
|
||||
* He added a version check so the PowerShell Classes don't cause issues for downlevel version of PowerShell
|
||||
* He added a version check so the PowerShell Classes don't cause issues for down-level version of PowerShell
|
||||
* He also contributed the first Pester tests for the module. Super! Check them out, they'll be the way tests will be implemented going forward
|
||||
|
||||
#### 4/18/2016
|
||||
@@ -658,7 +672,7 @@ Or
|
||||
#### 9/25/2015
|
||||
|
||||
**Hide worksheets**
|
||||
Got a great request from [forensicsguy20012004](https://github.com/forensicsguy20012004) to hide worksheets. You create a few pivotables, generate charts and then pivotable worksheets don't need to be visible.
|
||||
Got a great request from [forensicsguy20012004](https://github.com/forensicsguy20012004) to hide worksheets. You create a few pivotables, generate charts and then pivot table worksheets don't need to be visible.
|
||||
|
||||
`Export-Excel` now has a `-HideSheet` parameter that takes and array of worksheet names and hides them.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user