In brief..
The first line identifies the problem. The code was written some time ago, prior to the introduction of IDE version 1.0 (The sketch ends in .pde rather than .ino?)
The include file, WProgram.h, has been replaced by Arduino.h but if you do a search for WProgram.h you will find a lot of guidance of what you need to change to bring it up to date.
Plan B, not recommended, is download IDE 0022. It should compile then. However, that is going back three years.