The following are the ways I would use to overcome this problem:
1. Make sure you have also uploaded the PrecompiledApp.config file and check if its not containing any illegal characters in it. Remove if it has.
2. This also occurs when IIS has lost its mappings to ASP.NET. Then try this...
a. Open a command prompt
b. Change to the following directory (or whatever version of the .NET Framework you are using): C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
c. Run the command "aspnet_regiis.exe -i". This may take several minutes and will report the success/failure of the process.
Try now....worked? Yes (Cool)...or no (well sometimes it does not work, then reinstall IIS.)