Changed the project settings to target .NET version 3.5.