ASP.NET controls cannot be referenced in code-behind in Visual Studio 2008

前端 未结 16 1419
面向向阳花
面向向阳花 2020-12-25 12:28

Ok, so, my visual studio is broken. I say this NOT prematurely, as it was my first response to see where I had messed up in my code. When I add controls to the page I can\'t

16条回答
  •  盖世英雄少女心
    2020-12-25 12:36

    In my case, I was working with some old web site code, which I converted to a VS2008 solution. I encountered this same problem.

    For me, the fix was to right-click the Web Sites project in the Solution Explorer and select Convert to Web Application. This created designer.cs files for all pages, which did not yet have these files before.

提交回复
热议问题