Trying to attach script to object and getting parsing error!

I am trying to attach this C# script below to an object in my scene and I am getting a parsing error. Everything looks logiclly correct and I am frustrated with why I am getting this kind of error because it all looks correct to me.

I’d appreciate any help and pardon my rookie question since I know this has been asked before by many…

Error CS8025: Parsing error

public meshfilter
 
void start () {
    Mesh mesh = meshfilter.mesh;
    MeshHelper.Subdivide(mesh,6);   // divides a single quad into 6x6 quads
    meshfilter.mesh = mesh;
}

when posting errors, post the COMPLETE error message - there’s additional information such as line number and character position.

in your case, it’s because you don’t have a semicolon after your declaration of meshfilter.

also, unity won’t call start() for you… it will call Start() though :wink: