From 748cf0a772beacffcb4b1025c1a2fa2f15928030 Mon Sep 17 00:00:00 2001 From: Paul Williams Date: Wed, 23 Mar 2016 10:55:27 -0400 Subject: [PATCH] Allow ordered dictionary for PivotData --- Export-Excel.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Export-Excel.ps1 b/Export-Excel.ps1 index 9398ba5..3bc5468 100644 --- a/Export-Excel.ps1 +++ b/Export-Excel.ps1 @@ -269,7 +269,7 @@ function Export-Excel { } if($PivotData) { - if($PivotData -is [hashtable]) { + if($PivotData -is [hashtable] -or $PivotData -is [System.Collections.Specialized.OrderedDictionary]) { $PivotData.Keys | % { $df=$pivotTable.DataFields.Add($pivotTable.Fields[$_]) $df.Function = $PivotData.$_