Search the registry for a Value, and then use the Value's data

Hoping someone here can help me. I am attempting to find a binary value in the registry and I am having no luck so far. 
Here is what I currently have:
$key = "HKCU:\software\microsoft\office\15.0\Outlook\Profiles\Outlook"
Get-ChildItem $key -rec -ea SilentlyContinue | foreach {
$CurrentKey = (Get-ItemProperty -Path $_.PsPath -ErrorAction SilentlyContinue)
if ($CurrentKey -match "001f6700") {
$data = $CurrentKey.PSPath
$data2 = Get-ItemProperty -Path . -Name "001f6700"
echo $data2
# $data3 = [Text.Encoding]::ASCII.getString($data2)
echo $data3

Finally got it working with this code:
$x = Get-ChildItem HKCU:\software\microsoft\office -rec -ea SilentlyContinue |
Where-Object {(Get-ItemProperty -path $_.PSPath) -match "001f6700"} |
select -Property Property, Name, PSPath
$y = Get-ItemPropertyValue -Path $X.PSPath -Name 001f6700
for($i = 0; $i -clt $x.Count; $i++)
[Text.Encoding]::unicode.getString($y[$i].syncroot)
credit goes to a Mr. Nowacki

Similar Messages

Maybe you are looking for

  • How To Upload a Mime Object into BSP Application??

    Hi all, I am new to Developing BSP Applications. I have a requirement to design a BSP Page and in the header part of the page, i have to display a JPG file from my local PC. To achieve this, I did the following: 1) Upload/Import  the MIME Object(JPG

  • Maximum number of simultaneous NAT translations

    Hi all... Does anyone know how many simultaneous NAT translations a low end device such as a Cisco RV016 supports? I  know this is a low end device but I see no reason that with a typical  allocaiton of  220 bytes per entry and modern CPU's to walk t

  • Document termination error for sales return delivery

    Dear all, I got this error while doing PGR, for sales return. Acthually the material is with serial number, error description Update was terminated System ID.... DPT Client....... 900 User..... SDUSER Transaction.. VL02N Update key... 4E371CE1527FF18

  • Weblogic MBeanMaker and Sun JDK 1.4.2

    I just upgraded the JVM in my development environment to 1.4.2_04 and the Weblogic MBeanMaker no longer works. Has anyone seen this? The configuration is as follows: WLS 8.1 SP2 JDK 1.4.2_04 Windows 2000 The build script is Ant driven and I verified

  • Sales order with different Distribution channels

    Hi experts, how can i create a sales order with different distribution channels. I mean item level 10 = one distribution channel. Item level 20 = another distribution channel. also in Item level 30 also.... is it posible .?? how can i create ?? becau