The fixed part every PIF starts with. It is 0x171 bytes long. It is inherited from TopView, and Windows uses only part of it.
Microsoft has not published this layout. The fields and names below follow Michael Maurice’s article in Dr. Dobb’s Journal (July 1993); the program path, directory and title have been checked against real files.
Fields
0x00Reserved and checksum1 + 10x02Title, padded with spaces300x20Maximum and minimum memory2 + 20x24Program path630x63Flags and a drive byte1 + 10x65Start directory, then parameters64 + 640xE5screen, interrupts, window position and system memory100xEFShared program name and data file64 + 640x16Ftwo flag bytes1 + 1
| Offset | Size | Name | Description |
|---|---|---|---|
0x00 | 1 | Reserved | Zero in Windows PIFs. |
0x01 | 1 | Checksum | A checksum byte. In the 130 PIFs checked it matched the sum of the bytes from 0x02 only in a minority of files, so a reader should not trust it. |
0x02 | 30 | Title | The program’s title, padded with spaces. |
0x20 | 2 | Maximum memory | In KB. FFFF means as much as possible. |
0x22 | 2 | Minimum memory | In KB. |
0x24 | 63 | Program path | The program to run. |
0x63 | 1 | Flags | See Flags. |
0x64 | 1 | Default drive | Listed as the default drive by Dr. Dobb’s Journal. |
0x65 | 64 | Start directory | The directory to start in. |
0xA5 | 64 | Parameters | The program’s parameters. |
0xE5 | 1 | Screen mode | The video mode to start in. |
0xE6 | 1 | Text pages | The number of text pages to save. |
0xE7 | 1 | First interrupt | The first interrupt vector to swap. |
0xE8 | 1 | Last interrupt | The last interrupt vector to swap. |
0xE9 | 1 | Rows | Screen rows. |
0xEA | 1 | Columns | Screen columns. |
0xEB | 1 | Window row | The window’s position. |
0xEC | 1 | Window column | The window’s position. |
0xED | 2 | System memory | A value for older systems. |
0xEF | 64 | Shared program name | A shared program to load. |
0x12F | 64 | Shared data file | A data file for the shared program. |
0x16F | 1 | Flags 1 | A flag byte, its bits not established. |
0x170 | 1 | Flags 2 | A flag byte, its bits not established. |
Flags
The bits of the flags byte at 0x63, as Dr. Dobb’s Journal gives them. Only
Close on exit is said to be used in 386 enhanced mode.
| Bit | Name |
|---|---|
| 1 | Graph286 |
| 2 | PreventSwitch |
| 3 | NoScreenExch |
| 4 | Close on exit |
| 6 | COM2 |
| 7 | COM1 |