Why we should not place HKLM and HKCU keys in same component (as per the component rules) What is the reason behind it?
Answers (3)
If your component has HKLM and HKCU keys one of them (but only one) will be the key path.
If it is the HKLM key then after the s/w is installed HKLM and HKCU keys will be set but the HKCU key is only set for the person who installed the app. When another user (not the installer) starts the app the test on the key file will cause the writing of the HKCU key to be skipped as the HKLM key already exists.
If the HKCU key is the key path then each time a user starts the app for the first time, the HKCU key which is the key path doesn't exist so it and the HKLM key will get re-written causing a UAC activation if that user isn't an admin. It's a problem where an admin installs software for a non-admin user and it breaks ICE57.