The Old New Thing
Practical development throughout the evolution of Windows.
Latest posts
How do I make a boldface item on a context menu?
The menu default item.
Flaw reported in Windows 95
And a note from Mom.
Switching on a tuple: Sneaky trick
Data packing.
What's the difference between PathIsSystemFolder and Protected Operating System Files?
The way to detect weird directories that should be excluded from the user interface is to check for the and attributes being set simultaneously. This is the mechanism used when you uncheck Hide protected operating system files in the Folder Options dialog. (Programmatically, you detect whether the user wants to see protected operating system files by checking the member of the structure.) Michael Dunn suggested using to detect these special directories, but that is not quite right. is for marking a directory as "This directory has a nondefault UI behavior attached to it. Please consult the file for mo...
A Venn diagram demonstrating the dining options in one of the new cafeterias
Spelling out the options.
CancelIoEx can cancel I/O on console input, which is kind of nice
Stop that input.
Finding the constructor by scanning memory for the vtable
Reversal of fortune.
Sure, we have RegisterWindowMessage and RegisterClipboardFormat, but where are DeregisterWindowMessage and DeregisterClipboardFormat?
It not going away.
Travel tip: Don't forget your car on the ferry
One of my colleagues lives on Bainbridge Island and has quite a long commute to work each day. From his house, he walks to the bus stop, then takes the bus to the Winslow ferry terminal, then takes the ferry to the Seattle ferry terminal, then takes the bus to Microsoft. And at the end of the day, he does the trip in reverse. One day, for whatever reason, he drove to work instead of taking the bus. He drove to the ferry terminal, took the ferry across, then drove to work. And at the end of the day, he drove to the ferry, but when the ferry arrived at its destination, he forgot that he had driven his car and wa...