When Compiling my Web Deployment Project which references a Asp.Net project with a App_Browsers folder I get the following compilation error:
C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_compiler.exe -v /[PROJECTNAME].csproj -p "[FILEPATH]" -u -f -d .\TempBuildDir\
ASPNETCOMPILER : error ASPRUNTIME: Object reference not set to an instance of an object.
If I remove the App_Browsers folder everything works perfectly.
Any help would be appreciated.
Best Answer
Ok, finally found a solution.
As stated the aspnet compiler crashes when including the App_Browsers folder. So to avoid that, I have excluded the folder from the build and put in an "after build" action which copies the folder to the destination. This is done by adding the following lines of code to the deployment project file:
Hope it helps others, stuck with the same problem.