Totally stupid question, but I'm writing my first ASP.NET C# web forms application and sometimes I can just write a change and save it in Visual Studio and it works just dandy, but other times it seems I have to rebuild the project for changes to take effect.
Could anyone please tell me what conditions need to be met for me to rebuild?
Thanks!
Tom
Any changes to compiled code will require a rebuild. This includes:
The gotcha here is the word "compiled". Even the *.aspx *.asmx files are compiled, but this is done Just-In-Time (JIT) before the page is executed. The compiled output is cached and reused, but the runtime will detect changes to a few files and re-JIT them.
An interesting side: changes to the root web.config of your site will force a rebuild.
There are few changes that won't require a recompile.
TIP: If you have a large solution, with many projects, you don't have to re-compile every one of them each time you make a change. Just compile the projects that you have changed by right-clicking the project in Solution Explorer and clicking Build. If you have unsaved changes to files not in the selected project, these will not autosave and will be excluded from the build.
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.