Hello,
I am trying to extract each planar face of a roof drawn by a class I made (Following the same code on Jeremy's blog).
My code here is as follows:
HTML Code:
refLists = (List<Reference>)HostObjectUtils.GetTopFaces(roof);
foreach (Reference reference in refLists)
{
trans.Start();
var planFace = roof.GetGeometryObjectFromReference(reference) as PlanarFace;
planarFaceList.Add(planFace);
sketchplanesList.Add(SketchPlane.Create(doc, reference));
}
When I test this code against a manually drawn roof it works fine, but when I test it against the API drawn roof it doesn't respond, I also find the References are increased in number by 1 giving me 1 extra face that is not a planar face hence the error... I can't find a logical explanation so far!