How can I set the minimum required version of Windows with $SETPEFLAG
? It can be done with
editbin.exe "$(TargetPath)" /SUBSYSTEM:WINDOWS,5.01 /OSVERSION:5.1
for example.
You cannot set the minimum OS version using the {$SetPeFlags}
directive. You have to set it in the Project Options instead, on the Linking page:
Project | Options | Delphi Compiler | Linking
Set OS Version fields in PE header as <major>.<minor>
The default is 5.0 (Windows 2000).