The Old New Thing

Practical development throughout the evolution of Windows.

Latest posts

Nov 5, 2009
Post comments count 0
Post likes count 1

The day the coffee machine exploded

Raymond Chen

Some time ago, Microsoft began installing Starbucks coffee makers in the kitchens, and caffeine addicts waited anxiously for the machines to reach their building. Or at least that's what happened on the main Redmond campus. But what about the satellite offices? I'm told that each satellite office qualified for an iCup machine when the number of employees at the office reached some magic value. One of my colleagues who works at the office in New York City told me that they eagerly awaited the arrival of the machine when they learned that they reached that threshold. The long-anticipated day arrived: The coffee ...

Nov 4, 2009
Post comments count 0
Post likes count 1

In the product end game, every change carries significant risk

Raymond Chen

Exposure.

Nov 4, 2009
Post comments count 0
Post likes count 1

Good advice comes with a rationale so you can tell when it becomes bad advice

Raymond Chen

A customer asked for guidance in software design: Is there an issue with creating and using COM objects from a UI thread which was initialized as STA? I have heard that it is a best practice to create and use COM objects on a background thread which is MTA. I would like to have some more information as to why. Any help? (I still have trouble with the phrase best practice, especially when it is combined with the indefinite article: a best practice. It's like asking "Where is a tallest building?") Good advice comes with a rationale so you can tell when it becomes bad advice. If you don't understanding why somet...

Nov 3, 2009
Post comments count 0
Post likes count 0

When asked to choose among multiple options, the politician will pick all of them

Raymond Chen

During the run-up to a local election some time ago, the newspaper posed the same set of questions to each of the candidates and published the responses in a grid format so the readers could easily compare them. The candidates agreed on some issues, had opposing positions on others, but the question whose answers struck me was one of the form "If budget cuts forced you to eliminate one of the following four programs, which would you cut?" Notice that the first two candidates, when asked to make a tough decision, opted to make no decision at all. (Compare another election in which the mainstream candidates ra...

Nov 3, 2009
Post comments count 0
Post likes count 1

Microspeak: Net out

Raymond Chen

It started out in finance, but the term has crept into more mainstream usage (at least within Microsoft) and along the way picked up its own meaning: Where did we net out on this? Customers want you to net out the business value. Note any significant changes to the forecast and explain the reasons why. Net out changes to start conversation. Include the following points in your presentation: The next citation is a bullet point from a PowerPoint slide: Agenda Each district/vertical will answer/report back on: (I also have some finance citations, but they aren't relevant to Microspeak, so I've left ...

Nov 2, 2009
Post comments count 0
Post likes count 1

Hey, is there somebody around to accept this award?

Raymond Chen

Back in the late 1990s, some large Internet association conducted a survey in order to bestow awards in categories like Best Web server and Best Web browser, and one of the categories was Best Web authoring tool. We didn't find out about this until the organization contacted the Windows team and said, "Hi, we would like to present Microsoft with the award for Best Web authoring tool. Please let us know who the author of Notepad is, so that we can invite them to the award ceremony." Yup, Notepad won the award for Best Web authoring tool. The mail went out to the team. "Hey, does anybody remember who wrote Notep...

Oct 30, 2009
Post comments count 0
Post likes count 0

Still working out the finer details of how this Hallowe'en thing works

Raymond Chen

Here's an excerpt from a conversation on the subject of Hallowe'en which I had with my niece some time ago. Let's call her "Cathy". (This is a different Cathy from last time.) "Cathy, what do you do on Hallowe'en?" "You get all dressed up and people give you candy." "What do you say when people come to the door?" "Chuck-E-Cheese!"

Oct 30, 2009
Post comments count 0
Post likes count 1

What is the format for FirstInstallDateTime on Windows 95?

Raymond Chen

It tries to be DOS date/time format but misses.

Oct 29, 2009
Post comments count 0
Post likes count 1

What this batch file needs is more escape characters

Raymond Chen

(Employing the snowclone "What this X needs is more Y.") Each time you add a parsing pass to the batch processor, you have to add another layer of escaping. This is just a special case of the more general rule of thumb: any problem in quoting can be solved by adding another layer of escaping. (Okay, it's not actually true, nor is it a rule of thumb, but it's still something to keep in mind.) When you enable delayed variable expansion, you add another parsing pass to the batch processor. It used to expand % variables at the time the line is ready, but now you told it that, oh wait, just before executing t...