Mysterious VS.NET gremlins

Dec 28 2004 10:25 AM
Hi, I had an issue where all of a sudden, text that was being written successfully by the code-behind to the aspx file would stop showing up at all, with no error. I never, /ever/, use the designer. I started comparing the code generated by "#region Web Form Designer" in a test.aspx file that I had working, with the code of the files not working and I saw that somehow "this.Load += new System.EventHandler(this.Page_Load);" was removed from the "private void InitializeComponent()" event. Putting that back in fixes the issue. I certainly do not personally remove it and no one is working on this workstation except me and it continues to happen at seemingly random intervals after rebuilding (Alt B, R). It says right in that block: "Required method for Designer support - do not modify the contents of this method with the code editor." I /never/ use design mode and anyway I never modify that block, so I don't care about design mode, but by the same token, I can't have VS taking out code from that block willy-nilly with no way of knowing why or when. Anyone know why that could be happening? Thank you, Kyle

Answers (1)