The name XXXX does not exist in the current context

RadhaKrishnaKiJaya
RadhaKrishnaKiJaya used Ask the Experts™
on
Hello Experts,
I have a running project.  I added a new page and copied all the contents from an existing page.  Because my new page is quite similar to the existing one.  But when compiled, got too many errors.  Almost all the errors are like #1 and some are #2 errors as below.  Any idea what is going on?  Thank you very much in advance.

1. The name XXXX does not exist in the current context
2. The best overloaded method match for "MethodName(arguments)" has some invalid arguments
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Senior Developer
Commented:
The first error tells that the (most probably) the variable is not declared.
So, I believe, the page you have copied stuff from, have variables that are not declared in you current page/project, etc.
See https://msdn.microsoft.com/en-us/library/t8zbaa6f.aspx .


2. The best overloaded method match for "MethodName(arguments)" has some invalid arguments
This tells that the ""MethodName" method is used inappropriately. Most likely, in the code you copied from the name was same but the method signature was different.

Hard to tell more without looking at details.

Author

Commented:
Thank you  anarki_jimbel,
In fact Inherits was wrongly defined.  Now working fine.

Thank you again for your help.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial