Jump to content

No parameterless constructor defined


photo

Recommended Posts

Posted

Good evening,

To solve this issiue this part must be added:

    public class Example {
        public string name;
        public Example(){} // this part
    
        public Example(string name){
            this.name = name;
        }
    }

Why is this required?

public Example(){} 

 

×
×
  • Create New...