My app today started throwing the following error:
The name 'Control' does not exist in the current context
It’s happening only in 2 controls in the page, even if I rename them. If I add the control declaration myself in the .designer.cs file it works but when rebuilt it throws the error again.
Any ideas what might be wrong? I can paste all the code but I feel there’s just too much to paste, but if you want me to post some of the code just tell me.
The designer file for an aspx sometimes does no correctly write code for controls. so in such a case delete the designer file then right click on you .aspx file and Click “Convert to Web Application” this action regenerates the designer file again correctly