I used VS2010, and target for .Net 2.0 (VB.Net Windows Form application)
How to decide what is the .Net target I decided on 2.0 because I understood it will be OK if
Just because you installed .NET 4.0 doesn't mean your application was targeting .NET 4.0.
If you modify your project settings in Visual Studio to build to target .NET 4.0 and you should no longer get the error (but then your clients will need to install the .NET 4.0 Runtime).
Personally, if you want to release something that is going to run on the majority of client machines already out there, I would target .NET 3.5. Most people are going to have the runtime installed already.
If not, it's easy enough to download from Microsoft.
.