Code: Select all
import FreeCAD
for ii in range(2,205):
s1 = 'Wire023_child'+str(ii)
s2 = 'Wire023_child'+str(205-(ii-2))
if ii==103:
break
FreeCAD.ActiveDocument.addObject('Part::RuledSurface', 'Ruled Surface')
FreeCAD.ActiveDocument.ActiveObject.Curve1=(getattr(FreeCAD.ActiveDocument,s2),['Edge1'])
FreeCAD.ActiveDocument.ActiveObject.Curve2=(getattr(FreeCAD.ActiveDocument,s1),['Edge1'])
Even with the script I still ended up missing a couple ruled surfaces, but I was able to recreate them by manually. I think probably the line if ii==103 should maybe have been if ii==104, but I'm not sure. In any case now with all the ruled surfaces in place, use the Part -> Advanced utility to create shapes tool to make a shell from all the 2496 faces. Luckily there is an option in the dial to use all faces, which helps in the selection process, but there were still the ruled surfaces on the ends to select by hand. With the shell successfully created, next step is to use Part -> Convert to solid to turn the shell into a solid.
Hopefully all of this is as clear as mud. I had to delete all the history to make the file small enough for the forum. There are probably some tools in the Curves workbench that would have made this much easier, but I'm not familiar enough with them.