When I do this:
Rhino.RhinoDoc.ActiveDoc.Objects.Replace(meshTag.ObjRef.ObjectId, Sculpting.activeMesh);
it works and the old mesh got replaced.
But when I do this
Rhino.RhinoDoc.ActiveDoc.Objects.AddMesh(Sculpting.activeMesh);
it doesn’t work and the AddMesh() method returns with an empty Guid.