locked
Type ... not defined RRS feed

  • Question

  • In the codes of Designer of a form, wherever it displays System, for example:

    System.Diagnostics.DebuggerNonUserCode

    it is showing a red underline, meaning error, and the suggestion to repair the error message is:

    to enter the ProjectName.System.

    It does not want to recognize anymore the word System in the codes, only if I precede it with ProjectName.System

    Thursday, May 24, 2018 7:11 PM

All replies

  • Did you create some code object called System?  Did you recently rename something in the program?  It seems like you've caused a naming collision somewhere... Review any recent code changes that you performed prior to this error appearing.

    Reed Kimble - "When you do things right, people won't be sure you've done anything at all"

    Thursday, May 24, 2018 7:15 PM
  • How can I Check for this
    Thursday, May 24, 2018 7:52 PM
  • If you are using version control, check the change log.  If the project is not setup for version control you will have to remember what you have changed recently.

    Reed Kimble - "When you do things right, people won't be sure you've done anything at all"

    Thursday, May 24, 2018 7:53 PM
  • how can i find a namespace to delete it
    Thursday, May 24, 2018 9:02 PM
  • Everything is guessing. 

    But try this:

    Do Project -> Project Properties -> References 

    It should look a little bit like this and if not try to correct it with Adding and checking the boxes


    Success
    Cor

    Thursday, May 24, 2018 9:07 PM
  • You can use Edit -> Find to search for text in your code files. 

    I don't think it is a namespace as that would result in a different refactoring suggestion.

    Try searching for "Class System".  Creating a class named System will cause the error with the refactoring suggestion you mention.


    Reed Kimble - "When you do things right, people won't be sure you've done anything at all"

    Thursday, May 24, 2018 9:09 PM
  • I changed the name of my project

    and the "namespace" changed in the second

    this means

    that i cannot search for it

    because it became automatically changed 

    and now where can I find it to delete it

    Thursday, May 24, 2018 9:45 PM
  • Change the namespace back to the original project name, if you remember it.  It should be the name of the folder that was created when the project was first saved.

    Reed Kimble - "When you do things right, people won't be sure you've done anything at all"

    Thursday, May 24, 2018 10:30 PM