Can get-scsmobject get a specific property from an extended class?

Jun 29, 2012 at 4:13 AM
Edited Jun 29, 2012 at 8:23 AM

I am trying to pull a couple of properties from an extended service request fields. I have been attempting this with the get-scsmobject -class smlet but I can't seem to figure out how to get just the value of the property to pipe it to another command. Maybe I should be using another smlet?


Basically with

import-module smlets

$GetClass = Get-SCSMclass -Name ClassExtension_$

$GetObjects = Get-SCSMobject -Class $GetClass| Where-Object{$_.ID -eq "SR68"}

I can get the work item but I would like to pull values from my custom fields and write them to another field in this same class.

Jul 2, 2012 at 4:29 PM

I was able to get the Information that I was looking for by using this script from Andreas Baumgarten on the SCSM Technet Forums:

import-module smlets

# Get the extended class
$GetClass = Get-SCSMclass -Name ClassExtension_$

# Get the object of an extended class ID equal RA68
$GetObjects = Get-SCSMobject -Class $GetClass| Where-Object{$_.ID -eq "RA68"}

#Output Title of the extended Review Activity ID equal RA68

The Format List alias was helpful in showing me all the available properties in my extended workitem.