1.1 Comparison Between Windows 3.0/3.1 and Win32
The Windows 16 resource file is a file containing one or more binary resources. Each resource is preceded by a variable-length structure containing Type, Name, Flags, and Size. The Type and Name fields are either a string identifying the Type or Name, or a WORD value specifying the ordinal identity of the resource. The Flags field specifies to the system how to load into memory the resource, and the Size field specifies the size in bytes of the resource. The size, therefore, points to the next resource in the file.
The Win32 (both Windows NT and MS-DOS) resource file retains this structure, while expanding the header information with several additional values. It also adds a few fields to some of the predefined resources (Menu and Dialog, for instance), aligns all fields within the predefined resources on WORD or DWORD boundaries, and adds Unicode (16-bit character) support to the data structures.
One additional difference in resource files for Win32 is worth noting. This does not directly affect the structure of the resource file, but is rather a difference in how resource files are handled and incorporated into an executable image (DLL or EXE). Windows NT uses COFF format objects. Because of this, and the fact that the Win32 EXE format is much different from the Windows 16 format, the PDK provides a utility named CVTRES that converts a resource file into a COFF object. The linker then incorporates this object directly into the resulting executable image. No provision is made (as in Windows 16) for running the second pass of the resource compiler multiple times to update the resources: relinking the image is required.
However, the Win32 Application Programming Interface (API) provides a set of APIs that allow a program to enumerate all resources within an executable image, and update individual resources in the image.