The Old New Thing
Practical development throughout the evolution of Windows.
Latest posts
How do you drop on the background of an Explorer window when it is in details view?
When you set your Explorer to Details view, it can become tricky to drop an item onto the window background (in order to move it into the folder) because Details view sets full row select (starting in Windows Vista). This helps users of tablets and touch screens, because it increases the size of the target when dragging and dropping into a folder. On the other hand, when you have more items than fit on the screen, every pixel in the view corresponds to an item; there is no background any more. So how do you drop on the background? If you're using Windows 7, you can take advantage of a little gutter spa...
Programming means that sometimes you have to snap two blocks together
Part of the challenge of programming (and for some people, the reason why programming is fun in the first place) is looking at the building blocks provided to you and deciding how to assemble them to build something new. After all, if everything you wanted a program to do already existed ready-made, it wouldn't be called programming any more. It would be called shopping. Is there an API or a quick way to find out which window the mouse is in? I replied, "The LEGO Group does not make a piece for every possible object. Sometimes you just have to take two LEGO blocks and click them together. Here are some interes...
A burglar tells you the best place to hide your money
Jeffrey Strain chats with a former burglar and learns the best place to hide money. ("The bank," responds the former burglar. Oh, the best place to hide money in the house...) A month later, the follow-up article discussed the worst places to hide money (that sound like good ideas but aren't).
When giving a presentation with a diagram, pretend the diagram doesn't exist
::Wendy:: suggested enabling a means of displaying pictures on the blog without messing up the display of the whole post. Actually, I've simply given up on the pretty diagrams since everybody seems to hate them. You may have noticed that I've been using ASCII art instead. It's certainly easier for me to write, though it's also a bit uglier. One thing readers may not have noticed is that I try to make the article readable even without any diagrams or pictures at all. Sure, you can look at the diagrams if you want, but the article should still make sense if you don't. (And if the image is essential, I'll at lea...
How organizations inadvertently confirm facts when they try not to
On the Media in its story "Fact? Check!" forwarded the revelation (uncovered by the PBS program Frontline in the first part of their "News War" series) that the fact that the United States Justice Department launches a leak investigation implicitly confirms the leak! That's because one of the prerequisites for a leak investigation is that the leaked information actually be true. Lowell Bergman: The information has to be accurate? Dave Szady: Yes. Lowell Bergman: So when the government announces a leak investigation and it comes to your office, it's confirming that the report in the newspaper, for example...
What is the difference between Directory and DirectoryBackground?
One item I left off the list of special progids is . Recall that is the progid for file system folders (a subset of which represents all shell folders, both file system and virtual). Closely related is , which isn't really a progid, but it is a place where shell extensions can register themselves. Specifically, it's where context menu handlers can register if they want to appear when the user right-clicks on a blank space of a file system folder.
How do I quickly position two windows side by side using only the keyboard?
alexx is looking for a keyboard-only equivalent to the ctrl+click trick I mentioned a few days ago. Not as quick, but it still works. And it works even if the windows you want got converted into a group. Of course, on Windows 7, you can use the Win+Left and Win+Right hotkeys. (Users with multiple monitors can couple this with Win+Shift+Left and Win+Shift+Right.)
What is the difference between CSIDL_DESKTOP and CSIDL_DESKTOPDIRECTORY?
Among the various values you can pass to functions like are and . What's the difference between them? The is the virtual folder that represents the desktop. The contents of this virtual folder is what gets displayed on top of your wallpaper. The virtual folder is populated from various locations, some of them virtual, and some of them physical. The special folder is a physical folder that contains the files that you think of as on your desktop. These are the files that you've saved to your desktop, files that you've dragged to your desktop, that sort of thing. Some files on the desktop come from , which i...
The advantage of knowing your limits of discrimination
A story a while back about ridiculously expensive speaker cables and James Randi's challenge to tell the difference between them and modestly-priced cables reminded me of a conversation I had with a wine-loving friend of mine. He went on a wine tasting tour and sampled wines of varying quality and price. His conclusion was that he could detect the correlation between price and quality up until about $75/bottle. Beyond that point, the wines all tasted roughly equally great. Conclusion: There's no point in my friend spending more than about $75 on a bottle of wine. Once you know the limit of your discriminatio...