Click here to Skip to main content
15,889,909 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have created one web application in ASP.NET. But I have got error for each control as "control does not exist in current context" though control is already present on the page.

Plz give me any solution


Thanks
Posted
Updated 27-Nov-16 3:51am

Check your code behind file name and Inherits property on the @Page directive, make sure they both match. Add more details, if this doesn't help.
 
Share this answer
 
v2
IF your Code Behind file is correct and still you are having issue,the try this

1: Check your control attributes may be the tag is not properly formatted(may be there is no space between attribute For eg
<asp:textbox id="txt" runat="server" xmlns:asp="#unknown">

2: In your aspx file,instead of using Codefile use CodeBehind attribute
 
Share this answer
 
i have same issue after i removed the namespcase in the code behind the page, and my page source code is like this photo in this link

[^]
 
Share this answer
 
Comments
Dave Kreskowiak 27-Nov-16 11:30am    
You posted this an as answer to a question that was asked over FIVE YEARS ago.

Don't do that again. Post your own question.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900