On attempting to deploy a .net 3.5 website on the default app pool in IIS7 having the framework section set to 4.0, I get the following error.
There i
Apparently, other have (had) this problem. They rebuild in Framework 4.0. Can you?
Also, see this about making sure your IIS is fresh.