The Old New Thing

Practical development throughout the evolution of Windows.

Latest posts

When <CODE>Read­Directory­ChangesW</CODE> reports that a deletion occurred, how can I learn more about the deleted thing?
Mar 6, 2026
Post comments count 3
Post likes count 2

When Read­Directory­ChangesW reports that a deletion occurred, how can I learn more about the deleted thing?

Raymond Chen
Raymond Chen

It's already gone. If you need more information, you should have been remembering it.

The mystery of the posted message that was dispatched before reaching the main message loop
Mar 5, 2026
Post comments count 1
Post likes count 2

The mystery of the posted message that was dispatched before reaching the main message loop

Raymond Chen
Raymond Chen

Perhaps it's because you dispatched it.

Aha, I found a counterexample to the documentation that says that <CODE>Query­Performance­Counter</CODE> never fails
Mar 4, 2026
Post comments count 6
Post likes count 2

Aha, I found a counterexample to the documentation that says that Query­Performance­Counter never fails

Raymond Chen
Raymond Chen

Of course, anything can happen if you break the rules.

Just for fun: A survey of write protect notches on floppy disks and other media
Mar 3, 2026
Post comments count 17
Post likes count 1

Just for fun: A survey of write protect notches on floppy disks and other media

Raymond Chen
Raymond Chen

Just some useless trivia.

What sort of horrible things happen if my dialog has a non-button with the control ID of <CODE>IDCANCEL</CODE>?
Mar 2, 2026
Post comments count 3
Post likes count 1

What sort of horrible things happen if my dialog has a non-button with the control ID of IDCANCEL?

Raymond Chen
Raymond Chen

You get notifications that might not make sense.

Intercepting messages inside <CODE>Is­Dialog­Message</CODE>, fine-tuning the message filter
Feb 27, 2026
Post comments count 3
Post likes count 2

Intercepting messages inside Is­Dialog­Message, fine-tuning the message filter

Raymond Chen
Raymond Chen

Making sure it triggers when you need it, and not when you don't.

Intercepting messages inside <CODE>Is­Dialog­Message</CODE>, installing the message filter
Feb 26, 2026
Post comments count 1
Post likes count 2

Intercepting messages inside Is­Dialog­Message, installing the message filter

Raymond Chen
Raymond Chen

Using an <CODE>Is­Dialog­Message</CODE> extension point.

Intercepting messages before <CODE>Is­Dialog­Message</CODE> can process them
Feb 25, 2026
Post comments count 4
Post likes count 1

Intercepting messages before Is­Dialog­Message can process them

Raymond Chen
Raymond Chen

Process the message before you let <CODE>Is­Dialog­Message</CODE> see it.

Customizing the ways the dialog manager dismisses itself: Isolating the Close pathway
Feb 24, 2026
Post comments count 2
Post likes count 2

Customizing the ways the dialog manager dismisses itself: Isolating the Close pathway

Raymond Chen
Raymond Chen

Intercepting the flow in your message loop.