title: How to get the installed path from the registery?
body: <p>I am trying to get the installed path from the registry. I have installed the python in my machine. I want to get the installed path from the registry in VC++ 6.0. I am trying the following code but it is returning error code (87) that means file not found:</p>
  
  <pre><code>dwRet = RegQueryValueEx( HKEY_LOCAL_MACHINE,
                           TEXT("SOFTWARE\Python\PythonCore\${PYTHON_VERSION}\InstallPath"),
                           NULL,
                           NULL,
                           (LPBYTE)cbData,
                           NULL );
  </code></pre>
  
  <p>Any idea?</p>
  
  <p>Thanks,</p>