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

New Post: Change notes field of existing Request Offering

$
0
0
Hi all,

When we try to change the "notes" field of a request offering we get the following error:
Set-SCSMObject : Cannot process extension elements as EnterpriseManagementObject. User EnterpriseManagementObjectProjection for all extension element CRUD operations.
At ...\Untitled1.ps1:5 char:7
+ $RO | Set-SCSMObject -Property Notes -Value "Test"
+       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Set-SCSMObject], InvalidOperationException
    + FullyQualifiedErrorId : System.InvalidOperationException,SMLets.SetSMObjectCommand
Our code looks like this:
Import-Module smlets
$ROName = "RequestOffering"
$compName = "Note"
$RO = Get-SCSMClass -Name System.RequestOffering | Get-SCSMObject | Where-Object {($_.Title -like "*$ROName*") -and ($_.notes -eq "$compName")}
$RO | Set-SCSMObject -Property Notes -Value "Test"
Any help will be appreciated.

Viewing all articles
Browse latest Browse all 306

Trending Articles



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