Friday, November 14, 2008

Error: ASPX page has not been pre-compiled, and cannot be requested

Sometime we find that our web site was working perfectly on our development machine but start displaying error “ Error: ASPX page has not been pre-compiled, and cannot be requested” in many of forums I foud many of our peers are still struggling with same issue.

The simple workaround for that I have found is :

1. If you are using any 3rd party component , remove them from web.config, then using Add Reference add all reference to them again.
2. Instead of setting the WDP's Output Assemblies property to “Merge all outputs to a single assembly” and deploy, use Publish Web Site under the Build menu.
3. Check the "Allow this precompiled site to be updatable" check box in the Publish Web Site options of Visual Studio 05, and deploy.
4. make sure you uploaded all the required assemblies. If anyone is missing upload that manually.

Hope this information will be helpful to my peer community.