CoffeeFiend Posted August 27, 2004 Share Posted August 27, 2004 It seems that the tweak to have the F-Lock always on breaks the other keyboard layouts, so I was wondering, perhaps we could try to see if one of the keyboards that needs the tweak is plugged in before applying it? (otherwise not apply the tweak)The only ones I use that need it are the microsoft office keyboards, they have a Vendor ID of 045e and a Product ID of 0048. So we can check for HKLM\SYSTEM\CurrentControlSet\Enum\USB for subkeys that match that (Vid_045e&Pid_0048) with a script. Actually, we could even search for the actual name (Microsoft® Office Keyboard) but I think it would just tend to not detect sometimes (if the USB device is plugged, it will have a good VID/PID, but if the name is always proper... I'm not 100% sure).The only thing is, I'm not sure if the keyboard is actually detected at the phase I run my tweaks (GUIRunOnce)... I'll test it soon enough.Any VID\PID for other keyboard that would benefit from that are more than welcome too.Anyways. Here's what I'll try:@echo offset tmpFile=C:\usb.logREGEDIT /E tmpFile "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\USB" > nulfind /i "\Vid_045e&Pid_0048]" tmpFile > nulif errorlevel 1 goto NotNeededREGEDIT /S "%cdrom%\install\RegTweaks\FLock.reg":NotNeededdel tmpFile set tmpFile=I'm also open to different ideas or a better script. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now