4

We're using Sitecore PowerShell Extensions to generate some reports. In one of our templates we have a field with the name Id. This id field is not being listed correctly by PSE because it is conflicting with the Item Id from Sitecore. How would we get our own id field in PSE instead of the Sitecore ID?

This is the shortened code.

Get-ChildItem -Path $root -Language * | Show-ListView -Property Id,Description
6

Using the "Name/Expression scheme" I was able to retrieve the field just like in C#. This gets the correct field value.

Get-ChildItem -Path $root -Language * | Show-ListView -Property `
                 @{Label="Id"; Expression={$_.Fields["Id"].Value}}

Your Answer

By clicking "Post Your Answer", you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.