How can I append to a file and know where it got written, even if the file is...
A customer had a collection of processes, all of which are writing to a single file. Each process wants to append some data to a file and also know where the appended data was written, because the...
View ArticleIn order to serve you better: Charging your credit card in your home currency
Dynamic currency conversion is a service provided by merchants when processing credit cards payable in a foreign currency. Say, for example, you present a credit card issued by a United States bank to...
View ArticleEnumerating all the programs that can open a particular file extension
Today's Little Program enumerates all the applications which are registered for a particular file extension and lets the user choose one. We then open a file with that chosen program. As always,...
View ArticleWhat does Ctrl+Enter mean? It depends on whom you ask
One of my colleagues was baffled by why Outlook displayed this message: Microsoft Outlook⚠ You pressed CTRL + ENTER. Do you want to use CTRL + ENTER as a keyboard shortcut for sending a message? ☐ Do...
View ArticleHidden gotcha in the thread pool sample program on MSDN
There's a hidden gotcha in the MSDN thread pool sample that one of our interns stumbled across. "I am trying to create a simple thread pool rather than creating a new thread for each task I want to...
View ArticleA question about how to detect whether Windows Update needs the system to be...
A customer wanted to know whether there was a way to detect that Windows Update has recently installed an update that requires a reboot. They explained that their computers are running dedicated...
View ArticleWhy did disabling interrupts cause Windows 95 to hang?
One of the ways people used to demonstrate the awfulness of Windows 95 was that you could hang the system with this simple two-instruction MS-DOS program: cli jmp $ The cli instruction disabled...
View ArticleClarifying the documentation on wildcards accepted by...
A customer asked for clarification in the documentation for FindFirstFile and related functions, such as FindFirstFileEx and FindFirstFileTransacted Does FindFirstFileEx support multiple...
View ArticleThe increasing urgency of a request to fill out a survey
Here are some email messages I received from an automated system. October 20: “This survey must be completed no later than November 14.” October 31: “Reminder, this survey must be completed no later...
View ArticleHow can I append to a file and know where it got written, even if the file is...
A customer had a collection of processes, all of which are writing to a single file. Each process wants to append some data to a file and also know where the appended data was written, because the...
View ArticleIn order to serve you better: Charging your credit card in your home currency
Dynamic currency conversion is a service provided by merchants when processing credit cards payable in a foreign currency. Say, for example, you present a credit card issued by a United States bank to...
View ArticleEnumerating all the programs that can open a particular file extension
Today’s Little Program enumerates all the applications which are registered for a particular file extension and lets the user choose one. We then open a file with that chosen program. As always,...
View ArticleWhat does Ctrl+Enter mean? It depends on whom you ask
One of my colleagues was baffled by why Outlook displayed this message: Microsoft Outlook ⚠ You pressed CTRL + ENTER. Do you want to use CTRL + ENTER as a keyboard shortcut for sending a message? ☐ Do...
View ArticleHidden gotcha in the thread pool sample program on MSDN
There’s a hidden gotcha in the MSDN thread pool sample that one of our interns stumbled across. “I am trying to create a simple thread pool rather than creating a new thread for each task I want to...
View ArticleA question about how to detect whether Windows Update needs the system to be...
A customer wanted to know whether there was a way to detect that Windows Update has recently installed an update that requires a reboot. They explained that their computers are running dedicated...
View ArticleWhy did disabling interrupts cause Windows 95 to hang?
One of the ways people used to demonstrate the awfulness of Windows 95 was that you could hang the system with this simple two-instruction MS-DOS program: cli jmp $ The cli instruction disabled...
View ArticleEnumerating all the programs that can launch a particular protocol
Today’s Little Program is a variation on the one from last time. This time, instead of enumerating all the handlers for a file extension, we enumerate all the handlers for a protocol. We then open a...
View ArticleHow do I register a command on the desktop background context menu? (And how...
To register a command to appear on the context menu for the desktop background, you put it under the predefined shell object DesktopBackground. (For some reason, this predefined object is not on the...
View ArticleWhy doesn’t findstr use the standard regular expression library?
Tim wonders why there isn’t a standard library that was settled on and used by everyone by now. (While you’re at it, why isn’t there a standard for electrical outlets that was settled on and used by...
View ArticleWhy does OpenProcess return access denied, even if I enable debug privilege?
Many customers ask something like this: We want to get the creation time of a process, but our call to OpenProcess fails with ERROR_ACCESS_DENIED. struct KernelHandleDeleter { public...
View Article