Pick Face from imported DWG (Mass Editor)

Pick Face from imported DWG (Mass Editor)

Anonymous
Not applicable
820 Views
1 Reply
Message 1 of 2

Pick Face from imported DWG (Mass Editor)

Anonymous
Not applicable

Hi All,

 

I have been trying to retrieve Face Reference from picked Face from imported DWG file:

Capture.JPG

and then create Divided Surface from the picked Face, that will have Nodes, so can be used to get points to place Adaptive Components. The problem is that the retrieved DividedSurface.HostReference

throws an exception:

Capture2.JPG

 

That it caused by the fact that I want to get DividedSurface from imported DWG - I have tried to get the Solid of the picked Face and bake it as FreeFormElement but then cannot get the Face of that element to use its Reference here:

 

DividedSurface ds = DividedSurface.Create(document, pickedRef);

 

Is there any workaround to create a DividedSurface on a picked DWG surface?

 

Edit: Tried to get the face of the picked element but it returns all the faces from the DWG.

0 Likes
821 Views
1 Reply
Reply (1)
Message 2 of 2

jeremytammik
Autodesk
Autodesk

Maybe you could convert it to a DirectShape instead of FreeFormElement and work with its faces there?

  

http://thebuildingcoder.typepad.com/blog/2015/11/flatten-all-elements-to-directshape.html

  



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

0 Likes