Alright, so I've got a working draft of a .NET plug-in (based on the my code [linked above], only ported to C#) which successfully turns on/off CAPSLOCK when AutoCAD got/lost focus respectively (thanks again, to Norman's guidance! [also linked above])... Additionally, I've added a CAPSLOCKAUTO CommandMethod, which allows the user to turn the plug-in on/off at will, and this setting is stored to the Registry for the current Profile, so one can have a different setting for each Profile (if desired, default setting is on).
Works great for activating another application window with left mouse click (even from taskbar), but in my testing, has undesired behavior when using Alt+Tab (which I use often)... Basically, the thumbnails that popup with Alt+Tab for one to scroll (tab) through cause the got/lost focus events to cycle (when they shouldn't, IMO)... I incorporated a test expression to first check for ((Control.ModifierKeys & Keys.Alt) == Keys.Alt), which prevents the unintended cycling of the got/lost focus events, but does not catch the lost focus event if the user does 'land' on another application window thumbnail via Alt+Tab.
... So it appears that I may need to create a WH_KEYBOARD_LL global keyboard hook (to incorporate an additional test expression [replacing the ... Keys.Alt bool test expression] in the plug-in's lost focus event handler, before actually executing further). *not sure*
If anyone has experience with this (catching Alt+Tab, etc. in such context), suggestions welcome... As soon as I can work this out, I'll create an Autoloader .bundle.
Cheers