The Old New Thing

Practical development throughout the evolution of Windows.

Latest posts

Jan 20, 2009
Post comments count 0
Post likes count 1

If you didn’t like the answer, asking the same question again is unlikely to help

Raymond Chen

I find it surprising how often this happens. A customer liaison will send a question to a mailing list like this: From: X To: Gizmo Discussion Hi, everybody. My customer is using the Gizmo Toolkit and wants to frob a gizmo without first registering as a frobber. They created the gizmo with , passing all the default flags, and then they call to attach the gizmo to a sprocket. When the sprocket detects that its host is decycling, it tries to frob the gizmo by calling , but the call fails. They can't register the sprocket as a frobber because the sprocket doesn't have the right frob context. They tried setti...

Jan 19, 2009
Post comments count 0
Post likes count 0

May the Horse Be With You: Stories from the racetrack

Raymond Chen

Only a Game interviews Harvey Pack [real], author of May the Horse Be With You, a collection of stories about horse racing. I don't really care much about horse racing, but I do love a good story, and Harvey Pack has a bazillion good stories.

Jan 19, 2009
Post comments count 0
Post likes count 1

Why isn’t the screen resolution a per-user setting?

Raymond Chen

Via the suggestion box, Dominic Self asks why screen resolution is a global setting rather than a per-user setting. Well, first of all, it's not even a global setting. It's a session setting. That it's not a global setting is not readily apparent most of the time since only Windows Terminal Server is set up to support multiple simultaneous interactive sessions. On Windows Terminal Server, you specify the properties of the virtual monitor you wish to connect with, including resolution, and the server accommodates your wishes. Well, up to a point. I mean if you ask for a 1,000,000×1,000,000 pixel screen, t...

Jan 16, 2009
Post comments count 0
Post likes count 1

You cannot pre-emptively reserve a file extension

Raymond Chen

The following question came in from a customer: If our program isn't installed and users double-click our document, they get sent to a Web site that presents a list of programs, but we want to send the user directly to our download site. How do we claim a file extension for our application? Um, you don't. You cannot pre-emptively reserve a file extension. If your program uses the extension and somebody off in another country working out of a garage also uses the extension , then that's fine. Of course, things get exciting when a user installs both your program and the garage program, but that's a conflic...

Jan 15, 2009
Post comments count 0
Post likes count 0

If you’re at a Thai restaurant with a Thai person who’s ordering food in Thai, and she asks you if you like your food spicy, think twice before answering

Raymond Chen

I think you see where this is going. I'm at a Thai restaurant with my sister-in-law, who is Thai. She's talking with the waitress in Thai, and she discovers that the restaurant's cook is someone she knows. And since she's from Thailand, she assumes the task of ordering the food, since she knows what's good and what isn't. During their conversation (entirely in Thai, so I don't understand a word of it), she turns to me and asks, "So, is spicy food okay?" I say, "Yeah, I like spicy food." Classic rookie mistake. I think that by the end of the meal, I had just started to regain the ability to taste th...

Jan 15, 2009
Post comments count 0
Post likes count 1

What is this magic setting that synthesizes Unicode from non-Unicode?

Raymond Chen

Commenter dan g. wonders how Windows can treat non-Unicode applications as Unicode via the Regional and Language Options control panel, specifically the part that lets you choose the Language for non-Unicode programs. "Having always believed that the only way to display, say, Chinese characters correctly was to compile with _UNICODE, this facility seems all the more remarkable." This setting is really not as magical as it appears. (After all, we had Chinese versions of 16-bit Windows that displayed Chinese characters just fine, and they certainly didn't use Unicode since Unicode hadn't been invented yet.) Mic...

Jan 14, 2009
Post comments count 0
Post likes count 1

The day shell.windows.com went down

Raymond Chen

When the file association Web service was first being developed, the programmer responsible for implementing the feature just scrounged around and found an old unused computer and set it up as a simple Web server under his desk, so there would be something to test the code against. That server happily churned away serving out file extension information, and when people asked for their program to be added, he would manually add it to the server. The server worked just fine, and like most things which work just fine, it was forgotten. And then remembered once things no longer worked just fine. I think it was ...

Jan 13, 2009
Post comments count 0
Post likes count 0

Excessive speed appeared to be a factor in the crash

Raymond Chen

In February 2007, a serious automobile accident took place in southwest Washington. A twelve-year-old boy was at the wheel of an SUV when he lost control and struck another vehicle. According to the sheriff's office, "Excessive speed appeared to be a factor in the crash." I dunno, I think a major factor is that a twelve-year-old was behind the wheel. Tragically, the boy sustained critical injuries and died the following day. There was an adult in the car who conveniently doesn't remember what happened, although there are rumors that this wasn't the first time that adult let the boy drive, and that the boy ha...

Jan 13, 2009
Post comments count 0
Post likes count 1

Where does shell.windows.com get information about file extensions, and how do I get in on that action?

Raymond Chen

If you double-click a file for which there is no registered handler, Windows will offer to visit the Web service on shell.windows.com to locate a program that can open it. But where does this information come from, and how can you add your program to the database? Knowledge Base article Q929149, titled Windows File Association System On-Boarding Process, provides step-by-step instructions on how you can add your file extension. If you look at the existing entries on shell.windows.com, most of them have relatively straightforward and neutral descriptions. "This document is a PowerPoint presentation." "This ...