Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# ASP.NET CSS .NET
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 23-Jan-13 19:15pm
Comments
Orcun Iyigun at 24-Jan-13 1:22am
   
Seems like you didn't remove textbox1 everwhere.. It is lurking somewhere and you have to find it.
Kavitha le at 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?
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

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.
  Permalink  
v2
Comments
Kavitha le at 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?
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

Change the Class name(both in .aspx and .cs page) which you have created. The new page is refering old page.
 
Thanks
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 4

Check that any where they are using ('<%= textbox.ClientID %>') if yes remove that instead of commenting.
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Whatever you had textbox1 talking to in the first copy is probably still trying to talk to it in the new one.
  Permalink  
Comments
Kavitha le at 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
0 OriginalGriff 693
1 George Jonsson 370
2 BillWoodruff 317
3 Sergey Alexandrovich Kryukov 259
4 Garth J Lancaster 240
0 Sergey Alexandrovich Kryukov 10,764
1 Maciej Los 5,474
2 OriginalGriff 5,472
3 CPallini 3,819
4 BillWoodruff 3,594


Advertise | Privacy | Mobile
Web03 | 2.8.141030.1 | Last Updated 24 Jan 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100