Merge pull request #81 from brianaddicks/master

Added ValidateScript block to Path parameter for Import-Excel
This commit is contained in:
Doug Finke
2016-03-30 09:46:41 -04:00

View File

@@ -29,6 +29,7 @@ function Import-Excel {
param(
[Alias("FullName")]
[Parameter(ValueFromPipelineByPropertyName=$true, ValueFromPipeline=$true, Mandatory=$true)]
[ValidateScript({ Test-Path $_ -PathType Leaf })]
$Path,
[Alias("Sheet")]
$WorkSheetname=1,