Quantcast
Channel: SCSM PowerShell Cmdlets
Viewing all articles
Browse latest Browse all 306

Commented Unassigned: get-scsmobjecttemplate: value cannot be null [11507]

$
0
0
i use the smlets to automate tasks in orchestrator.
I have the smlets installed and succesfully working for a few weeks.

no suddenly when i do the following:
get-scsmobjecttemplate -displayname "templatename"

i receive the error:
Get-SCSMObjectTemplate : Value cannot be null.
Parameter name: input
At line:7 char:18
+ $FoundTemplate = Get-SCSMObjectTemplate -DisplayName “templatename“
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Get-SCSMObjectTemplate], ArgumentNullException
+ FullyQualifiedErrorId : System.ArgumentNullException,SMLets.GetSCSMObjectTemplateCommand

the Get-SCSMObjectTemplate command without parameters returns the complete template list correctly without errors.

any ideas?
Comments: ** Comment from web user: bobske **

I have experienced the same, it's a little random. I think it's a bug in the cmdlet. Try using -Name or -Id instead, this also finds it faster. If it's just for looking up something you could of course pipe it to a ?{$_.Displayname -like "*templatename*"}


Viewing all articles
Browse latest Browse all 306

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>