Click here to Skip to main content
15,896,118 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

i am working in vc++.
I wrote the following code..
its working for xp and above.
but its not working for 2000 server..
can you help me..

Code:

C#
if( RegOpenKeyEx( HKEY_LOCAL_MACHINE,
    TEXT("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall"),
    0,
    KEY_READ|KEY_WOW64_32KEY,
    &hTestKey) == ERROR_SUCCESS
    )
{
    printf("RegOpenKeyEx ---- >Success");
 
}
else
{
    printf("RegOpenKeyEx ---- >Failed %d",GetLastError());
}
Posted

1 solution

No luck: documentation[^] states that the KEY_WOW64_32KEY is NOT supported by Windows 2000.
 
Share this answer
 
Comments
@BangIndia 3-Apr-12 6:33am    
Thanks sir.
CPallini 3-Apr-12 6:36am    
You are welcome.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900