Search code examples
asp.net-mvcazurerazorpublishasp.net-mvc-views

Specific View not updating content after publish


This is the new little code on my View.cshtml:

@Html.HiddenFor(i => i.vVendaUnitarioSemImpostoSemFormatacao)

When I'm on debug mode, it works normally, but when I put in release mode and publish on azure, doesn't update what I've codded.

I've already tried:

  1. Click on compiling before publishing in visual studio options.
  2. Tried to set true on .csproj <MvcBuildViews>true</MvcBuildViews>
  3. Publishing from another computer
  4. Change another View from my project and works normally, but that one specifically don't.
  5. Tried to put optimizeCompilations="true on <compilation> in web.config
  6. Tried to copy and paste on ftp project to check if will work.

Someone can help me on that?


Solution

  • I saw this post Certain Razor views not publishing . What I did to resolve the problem was create another view, with another name and change the code where I'm calling the old view.