From fd38a590805b0ebe0ed782aca255d1d680973357 Mon Sep 17 00:00:00 2001 From: Daniel Brennand <52419383+dbrennand@users.noreply.github.com> Date: Wed, 17 Apr 2024 08:56:09 +0100 Subject: [PATCH] fix: https://github.com/dfinke/ImportExcel/issues/1587 --- Public/Import-Excel.ps1 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Public/Import-Excel.ps1 b/Public/Import-Excel.ps1 index 3734f2bc..a63a0cda 100644 --- a/Public/Import-Excel.ps1 +++ b/Public/Import-Excel.ps1 @@ -176,6 +176,9 @@ if ($StartRow -eq 1 -and $EndRow -eq 1) { $rows = 0 } + elseif ($StartRow -eq $EndRow) { + $rows = 0 + } } # ; if ($StartRow -ge $EndRow) { Write-Warning -Message "Selecting $StartRow as the header with data in $(1+$StartRow) to $EndRow might give odd results." } }