Hi,
Need some advice on writing to HKCU when multiple users are logged-on. We have currently vbscript to update trusted sites, and I’m looking at converting this to Action Script. The script works fine in 90% of our cases however I’m running into issue when I target devices where multiple users are logged-in, I’m trying to find a way to update these user hives in such scenario.
Fixlet (Small snippet)
createfile until @end_create_reg_file
Windows Registry Editor Version 5.00[{current user keys (logged on users) of registry}\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\abc.com]
“http”=dword:2
“https”=dword:2
“*”=-
@end_create_reg_filemove __createfile update.reg
waithidden regedit /s “update.reg”
we also have corresponding relevance to check for this and re-apply if neccessary
(not exists value “http” whose (it as integer = 2) of keys “SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\abc.com” of current user keys (logged on users) of native registry) Or (not exists value “https” whose (it as integer = 2) of keys “SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\abc.com” of current user keys (logged on users) of native registry)
If I’m not using the plural version then I get error message when multiple users are logged-in.
I’m looking for easy way (if possible wtih Action Script) to update keys when multiple users are logged-in. With our VBScript we basically iterate over the user hives and update each hive accordingly, have not found a way to do this using Action Script. I could possible explore the option using PowerShell but then still need to find a way for the relevance to become false in scenario with multiple users
any suggestions/ideas are welcome
Thx!