In my previous post I explained how to fix the issue with the default date format provided in the AssemblyVersionTask. Several people encountered the problem with the arrival of 2007, and all of them sent me mail about it :) After providing them with the fix, a few people wrote back and commented (with variying degrees of politeness) that my code was bad and that I should change it to support a larger build number.

That's a mighty fine suggestion, but unfortunately the limitation isn't in my code, it's imposed by the operating system:

Binary version number for the file. The version consists of two 32-bit integers, defined by four 16-bit integers. For example, "FILEVERSION 3,10,0,61" is translated into two doublewords: 0x0003000a and 0x0000003d, in that order. Therefore, if version is defined by the DWORD values dw1 and dw2, they need to appear in the FILEVERSION statement as follows: HIWORD(dw1), LOWORD(dw1), HIWORD(dw2), LOWORD(dw2).

So, I'm sad to say, we will be stuck with 16-bit build numbers forever.

[ Author: Neil Enns ]