Okay well I redid the code and now its working.
But now I want to go to that directory I tryed using
int main ()
char rgValue ;
char fnlRes ;
if( RegOpenKeyEx( HKEY_LOCAL_MACHINE,
KEY_QUERY_VALUE, &keyHandle) == ERROR_SUCCESS)
RegQueryValueEx( keyHandle, "Path", NULL, &Type,
printf( "Your path is %s\n", rgValue );
else strcpy(fnlRes,"Somesoft is not installed on your computer!");
And as I expected it didn't work any help?
EDIT: fixed every thing works