Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error while omite OutPutFormat parameter #12

Open
LaurentLienhard opened this issue Feb 15, 2020 · 2 comments
Open

Error while omite OutPutFormat parameter #12

LaurentLienhard opened this issue Feb 15, 2020 · 2 comments

Comments

@LaurentLienhard
Copy link
Contributor

When you use this without OutPutFormat parameter

Find-FUFunction -Path .\BuildOutput\PSItSupport\PSItSupport.psm1 | Write-FUGraph -ExportPath ".\Docs\MyGraph.png"

I have this error

Write-FUGraph : Parameter set cannot be resolved using the specified named parameters.
At line:1 char:68
+ ... ort\PSItSupport.psm1 | Write-FUGraph -ExportPath ".\Docs\MyGraph.png"
+                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (FUFunction:FUFunction) [Write-FUGraph], ParameterBindingException
    + FullyQualifiedErrorId : AmbiguousParameterSet,Write-FUGraph
@LaurentLienhard
Copy link
Contributor Author

I think it's related to ParameterSet
If you comment on ParameterSetName in your function no more worry

[00:09.071] | PSItSupport> Find-FUFunction -Path .\BuildOutput\PSItSupport\PSItSupport.psm1 | Write-FUGraph -ExportPath ".\Docs\MyGraph.png"

[00:09.819] | PSItSupport> 

@LaurentLienhard
Copy link
Contributor Author

or you put DefaultParameterSetName = "Graph" in your cmdletbinding

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant