Import-Html.ps1
function Import-Html { [CmdletBinding()] param( $url, $index, $Header, [int]$FirstDataRow=0 ) $xlFile = [System.IO.Path]::GetTempFileName() -replace "tmp","xlsx" rm $xlFile -ErrorAction Ignore Write-Verbose "Exporting to Excel file $($xlFile)" $data = Get-HtmlTable -url $url -tableIndex $index -Header $Header -FirstDataRow $FirstDataRow $data | Export-Excel $xlFile -Show -AutoSize } |