Query AD PowerShell Activity for ObjectGUID returning System.Byte[] - DirectoryService - how to convert byte array to guidDescriptionQuery AD PowerShell Activity for ObjectGUID returning System.Byte[] The Query AD PowerShell Activity is using System DirectoryService to query ActiveDirectory. Thus the property: objectguid returned is in byte array format. This is further converted by ConvertTo-Json and ends up as "System.Byte[]". ResolutionIn Script Files > ActiveDirectory.psm1 change below lines: foreach ($propertyName in $searchResult.Properties.PropertyNames) { $propertyValue = $searchResult.Properties[$propertyName]; if(($propertyValue.Count) -gt 1 ) { $jsonObject.$propertyName = $propertyValue; } else { $jsonObject.$propertyName = "$propertyValue"; } } to foreach ($propertyName in $searchResult.Properties.PropertyNames) {$propertyValue = $searchResult.Properties[$propertyName];if(($propertyValue.Count) -gt 1 ) {$jsonObject.$propertyName = $propertyValue;} else {if($propertyName -eq "objectguid") {$jsonObject.$propertyName = $(New-Object -TypeName System.Guid -ArgumentList @(,($searchResults.Properties["objectguid"][0]))).guid;}else {$jsonObject.$propertyName = "$propertyValue";}}}