I have some questions about the registry.
We have
Preferences p = Preferences.userRoot();
If we execute
p.nodeExists("/HKEY_CURRENT_USER/Software/Policies/Microsoft")
it will return true.
After it:
p = p.node("/HKEY_CURRENT_USER/Software/Policies");
for(String s : p.childrenNames()){
System.out.println(">" + s);
}
We see that it has one child: “Windows”. But
p.nodeExists("/HKEY_CURRENT_USER/Software/Policies/Microsoft/Windows")
returns false. Why?
Thanks.
UPDATE
Ok. I have some mistakes. Let me try again: Why does
p.nodeExists("/HKEY_CURRENT_USER/Software/Policies/Microsoft/Windows")
return false?
If you execute the code lines shown, in the order shown, when you get to the line
pdoes not anymore point to the user root, but to “/HKEY_CURRENT_USER/Software/Policies”.Btw you have a probable omission in your third code sample:
should be