Designer file not updating asp net

14-Nov-2015 22:36 posted by gymslip | Leave a comment

For some reason my old designer file got “messed up” and was placed under the file…long story short, it didn´t work and a had to delete it. I started to search for the problem online and got some answers.

What also works in some situations is to first delete the designer file (.cs), not the code behind, and the save and close the solution file.Re-open it and then choose “Convert To Web Application” and the designer is the “fixed”.Raise your hand if this has happened to you (i know it has to me a LOT of times recently): You’re working on a Web Application Project (WAP) page in markup and you paste in some code from another page.All of a sudden you notice that the page’s generated control definitions (in the .file) no longer update.You create new controls in markup or the designer and – they don’t show up in your code.Even though you know the control is defined on the page you’re in red squiggly hell: So now comes the dance: You’re trying to open the markup editor, make some changes. Open the designer, move something, compile try again… The problem here is that the designer file doesn’t get re-generated if you have some sort of layout error in the page.

Specifically WAP pages look at the page markup and then build the .(.vb) file.

If there’s a problem in your codebehind with controls not showing up as above the problem usually is that the designer file is empty (if the page was created new with an error) or not updated again.

I got stuck on a problem (related to the title of this post) today and thought I´d share my experiences (and how I solved it).

I had a class library project that I wanted to change into a web application project and copy some stuff from an old web application project that I had.

That was done by editing the project file like this: Add Just open a web application project and copy from that. The problem was when I started to add User Controls (ascx) and Web Forms pages (aspx) to my “new” project from my old UI project.

I dragged and dropped them into my new project and changed the namespaces and the inherits attributes.

Leave a Reply

  1. contemporary dating patterns 16-Oct-2015 12:00

    Chad Stone is a nationally known dating and relationships expert and writer.

  2. Photo adult galerie 05-Nov-2015 08:29

    Contact us today to find out all the benefits of choosing Guangzhou Car Service as your trusted limousine service provider in Guangzhou!

signing and dating doctors orders