the type "src" does't exist in the type 'minecraftDevelopper
hello
I am trying to make a personalized button in order to subsequently integrate a translation system into this first application that I am coding.
the problem is that I have this error and I don't understand why I have it on the build
24 Replies
anyone can help me ? 🙂
can you show the error through a screenshot?
its write in french, but in give the compiler error : CS0426
in the design
ic, u probably have a class called MinecraftDevelopper conflicting with the namespace
I always put one class per file
there it is
the issue ur namespace and class have the same name. like R said
1>C:\Users\jacques\source\repos\MinecraftDevelopper\Acceuil.Designer.cs(87,37,87,40): error CS0426: Le nom de type 'src' n'existe pas dans le type 'MinecraftDevelopper'
my class that I want to take does not have the same name
it does
here's proof
the problem is its trying to look for a property/field called src in this class
Okay, does that mean I completely screwed up the architecture? because I want to use as namespace MinecraftDeveloper/src or /assets
i advise you to change the name of this class, then ur code will work
no, your namespace is fine
you could call this class
Acceuil
to match it's filenameOK, I understand better.
but why when I created this project on visual, by default it gave me this?
what do you mean?
I mean that visual studio, when I created the project, automatically created this code for me. I just wanted to directly make my custom button to prepare (because I want to add a translation system)
what code are you talking about?
when you create a class through visual studio, it always generates a class and a filename of the same name with
.cs
file extension