Install DirectX before installing OFP.

I recommend making sure that Microsoft's DirectX program is installed before you install OFP. Also make sure you have DirectX version 8.1 or greater. Then, when OFP's setup program prompts you whether to install DirectX or not, simply don't.

The latest version of DirectX can be downloaded from Microsoft's DirectX page.