The directory '/website/App_Code/' is not allowed because the application is precompiled

前端 未结 4 910
旧时难觅i
旧时难觅i 2021-01-03 17:41

How can I resolve the below issue that I get when I am running my precompiled web app?

Server Error in \'/CRM\' Application.
    The directory \'/CRM/App_Cod         


        
相关标签:
4条回答
  • 2021-01-03 18:29

    In my case I compiled with "ASPX files are updateable" option checked OFF. I guess the IIS my website was running on did not like that.

    Once I recompiled with "ASPX files are updateable" option checked ON, the issue disappeared.

    0 讨论(0)
  • 2021-01-03 18:32

    In my case, I mistakenly, forced Publish a class, which caused this issue.

    The Solution was to make an update on the offending class, then Publish again with the option "Delete unused files from the Destination Site". (Which is under the publish modal options)

    0 讨论(0)
  • 2021-01-03 18:40

    Depending on your case, there are three possible scenarios:

    see this link http://www.beansoftware.com/ASP.NET-FAQ/Directory-App_Code-Not-Allowed.aspx

    Basically, If you precompiled your app, there shoudn't be an App_Code folder. If you added it later, you should delete it.

    OR

    May be Somehow a precompiled.config file has made it to production. Deleting that file should resolve the App_Code directory error.

    0 讨论(0)
  • 2021-01-03 18:44

    Deleting the "precompiledApp.config" file should solve your problem.

    0 讨论(0)
提交回复
热议问题