Click here to Skip to main content
15,891,529 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In my project i had to create one duplicate page for one page(aspx). So i copied the entire page (both aspx and aspx.cs files) .In my new duplicate i had to remove one textbox (textbox1)
so i removed it but nw am getting error that 'The name textbox1 does not exist in the current context'. Here we are using this textbox in javascript also but i removed that textbox everywhere but still getting same error.
please help as soon as possible.
Posted
Comments
Orcun Iyigun 24-Jan-13 1:22am    
Seems like you didn't remove textbox1 everwhere.. It is lurking somewhere and you have to find it.
Am Gayathri 24-Jan-13 2:27am    
I removed the textbox everywhere using find option.But still getting error
Is there any other reason or posibility for this error?

Hi,

You need to check textbox1 into .aspx.cs file. Search textbox1 into this file hope you will get one.

Or double click on the error and it will redirect you to that line where textbox1 is present.
 
Share this answer
 
v2
Comments
Am Gayathri 24-Jan-13 2:27am    
I removed the textbox everywhere using find option.But still getting error
Is there any other reason or posibility for this error?
Change the Class name(both in .aspx and .cs page) which you have created. The new page is refering old page.

Thanks
 
Share this answer
 
Check that any where they are using ('<%= textbox.ClientID %>') if yes remove that instead of commenting.
 
Share this answer
 
Whatever you had textbox1 talking to in the first copy is probably still trying to talk to it in the new one.
 
Share this answer
 
Comments
Am Gayathri 24-Jan-13 2:27am    
I removed the textbox everywhere using find option.But still getting error
Is there any other reason or posibility for this error?

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

  Print Answers RSS
Top Experts
Last 24hrsThis month


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