I was trying to get media item using media ID. I am getting the below error which I haven't faced before in powershell sitecore.
Scenario
$ImageId - {61630AC1F0E3111B9C50CEEE0B2B0223}
I am using the below command and getting below mentioned error:-
Get-Item -Path master: -ID $ImageId
Error
Get-Item : Expected hex 0x in '{0}'. Actual value: {61630AC1F0E3111B9C50CEEE0B2B0223}
The same command is working fine in 2 more places, is this a PowerShell extension bug ?
$item = Get-Item -Path "master:{path}" -Id "{6AA5AA9F-071A-4808-91AC-709FAAFFB310}" $mediaItem = [Sitecore.Data.Items.MediaItem]$item
Does this help?$parsedID = [Sitecore.Data.ID]$ImageId
?