简体   繁体   中英

iis and asp.net mvc compilation

as project is in developing state uploaded Files on webserver has not been compiled for easy editing and other reason , when i edit model and add property to view , iis say that your model has no that because of old compilation files , solution that Tested :

  1. Deleted Temp folder in windows\\microsoft.net
  2. <compilation batch="false" debug="true" targetFramework="4.5" />
  3. add new line to webconfig to force new compile

yet it run old compiled files

Based on the comments, I will add an answer...

You need to actually publish the application: How to publish a web app . You can publish this locally on your desktop and copy the files onto the server, or you can publish direct to your server.

When you publish the application, the model(s) get compiled into an assembly in your bin folder, so you cant directly modify these files on the fly.

You can chose a setting to allow for views to be updated, but this is very limited.

So, best approach is to set up a publish profile for your DEV server, and make your change, and then re-publish. It will take you less than a minute to get the latest code on the server.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM