Woohoo! One more of my "Programmers SE" answers has received a score of -5 !

The question is on a controversial topic, and as usual, I take the controversial stance.  So, it is no wonder that people do not agree with me.

Here is the question:

programmers.stackexchange.com: Does it make sense to use “ys” instead of “ies” in identifiers to ease find-and-replace functionality?


How to: Completely disable "Aero" in Windows 7

So, with Windows 8 sporting these god-awfully ugly opaque square boxes, which are not adorned in any way whatsoever, (not even the decent in all its simplicity gradient of Windows 98,) it seems like a confession on Microsoft's behalf that the spiffy "Aero" look of Windows 7 was nothing but an unnecessary gimmick afterall.

So, are you sticking with Windows 7 but want to disable Aero in order to enjoy considerable gains in performance, memory, power consumption, and GPU temperature? Here is how:
  1. Open up "Services". 
  2. Locate the service "Desktop Window Manager Session Manager". 
  3. Disable it and stop it. 


How to: Disable the administrative shares in Windows

To disable the administrative shares in Windows, (default shares like C$, ADMIN$, etc.) follow these steps:

1. Run the Registry Editor and go to the following key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet \Services\LanmanServer\Parameters
2. Create a new DWORD, name it AutoShareWks, and leave the default value of 0.

3. Reboot Windows.

This will disable things like C$ and ADMIN$.

I am not sure how to also delete print$ and IPC$.  ("net share ipc$ /delete" appears to work temporarily, but the share automagically re-appears after the next reboot.)

How to: Enable the Administrator account in Windows

To enable the Administrator account in Windows:

1. Open up an elevated command prompt.  (If you do not know what this is, you should not be even thinking of enabling the Administrator account.)

2. Type the following command:
net user administrator /active:yes


Solved: Windows: WiFi connect immediately after boot and before logon

In order to have your windows computer connect to your favorite WiFi access point immediately after booting, (without you having to first login to your computer,) follow these simple steps:

1.  First of all, make sure that this computer has connected before to the WiFi spot of interest.  (A so-called wireless profile is created as a result of this manual process.)

2. Run cmd.exe and issue the following command:
netsh wlan show profile
3. In the list of wireless profiles that are displayed, locate the one you want, and copy its name to the clipboard.

4. Run regedit.exe and navigate to this key:
5. Add a string value to this registry key.  Name it anything you like, and give it the following value:
%comspec% /c netsh wlan connect name="<profile name>"
Voila, next time you restart, your computer will immediately connect to this WiFi spot if it is in range.

Many thanks to user Soumya of superuser.com for posting this:http://superuser.com/a/133935/111757


Solved: cannot eject USB device: "This device is currently in use."

Millions of people all over the planet continuously have this problem: they try to eject their USB drive so as to avoid data loss, but windows does not allow them.  Which is very frustrating, because whatever reasons windows thinks it has for not allowing the removal should have lower priority than the user's explicitly stated direct wish to remove the damned thing!

Anyway, suggestions for solutions abound on the interwebz.  Here are some that I found with a quick search:

1.  Put your computer to sleep.  When going to sleep, Windows flushes all buffers to all devices, so while the computer is asleep, it is safe to remove the device.  The problem with this approach is that I don't want to have to put my bloody computer to sleep each time I want to take a USB device out.

2. Use SysInternals Process Explorer to search for the drive name, find which process has a handle open on the drive, and terminate it.  The problem is that drive names are only one a letter and a colon, a search for "D:" may yield thousands of handles from several dozen processes, all of which are unrelated to your drive "D".  Unfortunately, Process Explorer does not offer any option to search for a whole word only.  Another problem is that this approach hardly ever works.  Apparently, there are ways in which devices can be locked which do not show in Process Explorer.  Even if you remember to launch it as Administrator.

3. Select "Quick removal" policy as opposed to "Better performance" policy in the drive properties. The problem with this is that it is not really a solution: we generally do specifically want the better performance, and we are willing to sacrifice quick removal for it, accepting slow removal instead. But this issue is not one of slow vs. fast removal, it is about not being allowed to remove your device at all, ever!

Here is the solution which worked for me, after the above failed:

4. Make sure that the drive, or any folders in it, are not shared on the network!  (Use "NET SHARE" on the command prompt to quickly find out what you are sharing.)

Solved: The network folder specified is currently mapped using a different user name and password

So, I am on computer A, trying to map a local drive to a shared folder of computer B, and Windows gives me this message: "The network folder specified is currently mapped using a different user name and password".  

Microsoft supposedly addresses this issue here: https://support.microsoft.com/en-us/kb/938120 and concludes that it is so by design.

Bullshit.  They are missing the point.  The error message is wrong.  The network folder specified is not currently mapped using a different user name and password. Instead, what is happening, is that another folder of the same computer B is already mapped on computer A using a different user name and password. 

So, apparently, with windows, if you connect from computer A to any share of computer B, then all subsequent attempts to connect from computer A to other shares of computer B must be done using the same credentials.  Go figure.


The GWX (Get Windows 10) KB3035583 trojan horse

So, Microsoft has pushed this trojan horse to every single user of Windows on the planet.  It displays a Windows 10 logo on the taskbar, and it is basically telling you that not only you will get Windows 10 as soon as it comes out, but you should right now begin acting as if you are looking forward to it. Because, you know, you are their biatch.

So, let's see:  a) GWX installs on your machine without your consent; b) once installed, you cannot "quit" it or "exit" it; and c) you cannot find it anywhere to uninstall it.  So, it fits squarely within the definition of malware.

GWX is delivered by means of an innocent looking optional update, KB3035583.  The update is designated as "Recommended", and its description says "Install this update to resolve issues in Windows. For a complete listing of the issues that are included in this update, see the associated Microsoft Knowledge Base article for more information."  (I am not making this up, that's exactly what it says, I suppose English is not their forte at Microsoft.)

Of course, with dozens upon dozens of updates each time you check, which give you no clue as to what they are about, and instead each one of them refers you to some web page for more information, you don't bother checking, and so you passively consent to this trojan horse being downloaded and installed on your computer.  If you click on "More information", you are taken to a web page which admits that update KB3035583 is nothing but an incredibly lame and stupid publicity stunt about the upcoming Windows 10.

And so, as it turns out, that bit about resolving issues in Windows was a fucking lie.

How to get rid of the KB3035583 trojan horse:

1. In Windows Update select Change settings, and make sure that "Give me recommended updates the same way I receive important updates" is unchecked.  This way, the fact that this is a "Recommended" update will not cause it to jump from the "Optional" updates list to the "Important" updates list.

2. In Windows Update select View update history, find KB3035583, and uninstall it.

3. In Windows Update click on "Check for updates".

4. In Windows Update go to Optional Updates, find KB3035583, and specify that you want it to be hidden.

And then in 2017 there is this:
betanews.com: Microsoft will never again sneakily force Windows downloads on users
(Though it is unclear to me whether this is about Germany only or the whole world.)


Remote Desktop Connection quits without a word

So, I am firing up a remote desktop (RDP) connection, and the little box appears saying that it is trying to connect:

And then the box just disappears, without an error message or any other hint as to what might have gone wrong.

The interwebz abound with reports of this happening, and people asking how to fix it, and various solutions being offered that range from the complex to the hopelessly complex.

Luckily, every time I have encountered this problem, the solution for me was very simple: just wait and try again later.  The remote computer is probably busy booting, or perhaps booting and installing updates.

Now, I will tell you a little secret: when something goes wrong, software can ALWAYS give a meaningful error message.  If it does not, then someone, somewhere, is being either EVIL or INCOMPETENT.

If it could not find the server, it would have said that the server was not found.

If the server was not responding, it would have said that the server is not responding.

In this case, the server was actively refusing the connections, and someone at Microsoft was either so evil that they decided that in this specific case the software should not say anything, or, more likely, someone at Microsoft was so incompetent that they could not simply write their world-class software to give a meaningful error message in a very frequently occurring usage scenario.

Intel NUC5CPYH incompatible with Windows 7 Ulitmate 64 bit?

Intel advertises NUC5CPYH - (Celeron N3050) as being compatible with Windows 7.  It is not.  All my attempts to install Windows 7 Ultimate 64 bit on it failed.  The installation would start, and when it would reach the first interactive screen (language selection) the keyboard and mouse would be dead, (not even NumLock would work on the keyboard,) even though both keyboard and mouse work fine on the BIOS screens of the NUC.  On other occasions I managed to overcome this problem, (I don remember how,) and the installation would proceed to 99%, only to fail in the end with some error about not being able to update my computer's boot configuration or something.

Edit: be sure to read nucblog's comment below for a link to an article with instructions that might bring you more luck than I had.

In general, my overall experience of interacting with the BIOS of the NUC5CPYH was not pleasant at all.  The spiffy looking BIOS screens were not welcome by me, as they were not structured in the perfect logical order that I would expect of them, and certain parts of them were clunky.  Attempts to introduce an aesthetic upgrade which result in something technically more flawed than its ugly predecessor generally make a very bad impression, at least to me.

Perhaps the most annoying thing is that the initial screen with the prompts to press F2 to enter setup, F10 to enter the boot menu, etc. appears as if it requires not one, but two key-presses.  It probably requires only one, but there is an initial period of time during which if you press a key, that key is ignored, and that's extremely annoying.  Hey you, Intel BIOS programmers, I have a hint for you: if you are not ready to accept key-presses, do not display a prompt for them!