Click here to Skip to main content
15,886,518 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more:
I am trying to install straker game . it says internal error: failed to expand shell constance "commondocs". I looked it up and the person said to write a .TXT file that contains [HKEY_LOCAL_MACHINE\MACHINE\SOFTWARE\MICOSOFT\WINDOWS\CurrentVersion\Policies\system] "EnableLUA"=dword:00000000

What I have tried:

I do not know how to write it and save it.
Posted
Updated 11-Jan-23 10:22am

You have to be kidding. This is not programming, c++ or otherwise.

Open notepad or your text editor of choice. Copy the words after "contains" and paste them into the text editor. Then save that file and you are done. The Save option is usually under the editor's File menu.

BTW - This appears to be a registry file and everything up to the right square bracket (']') is one line and the text with "EnableLUA" should be on the second line. It should look like this :
[HKEY_LOCAL_MACHINE\MACHINE\SOFTWARE\MICOSOFT\WINDOWS\CurrentVersion\Policies\system]
"EnableLUA"=dword:00000000
 
Share this answer
 
Point 1: that will not work because you have mis-spelled Microsoft in the key, it should be:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System]
"EnableLUA"=dword:00000000

Point 2: modifying the system registry without understanding the effects can make your system unusable. So make sure you back everything up before making such a change. Also, see the warning at EnableLUA | Microsoft Learn[^].

If you make this change then your system will be potentially open to attack from viruses, trojan horses, ransomware, etc.
 
Share this answer
 
An easier and safer way to change the LUA settings is documented here:
3 Ways to Turn On / Off UAC in Windows 10 | Password Recovery[^]

For the sake of completeness, you can of course also write a C or C++ program for this. This would be a bit overkill, but possible. Here one could start:
RegOpenKeyExA function (winreg.h) - Win32 apps | Microsoft Learn[^]
 
Share this answer
 
v2

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