$RegKey = "HKLM:\SOFTWARE\Kofax\PDF\V1"
$Name = "VersionLong"

cls
if ((Get-ItemProperty $RegKey -ErrorAction SilentlyContinue).PSObject.Properties.Name -contains $Name) {
       Get-ItemPropertyValue $RegKey $Name 
   } 
   else 
   {
       Write-Host "The following Regisitry Key & Name does not exist: " -NoNewline
       Write-Host -ForegroundColor red "$RegKey\$Name"
   }