Cad.CurvesFromCADLayers return null

Hi everyone, i’m trying to get this small graph working 8(floors from cad imported polylines) using Bimorph CadCurvesfromCADLayers, i followed the user guide and tried different versions of the pBimorph package, but all in vain.
When i run the script i receive the following error (null return):
Warning: CAD.CurvesFromCADLayers expects argument type(s) (Element, string, bool, string), but was called with (var, DesignScript.Builtin.Dictionary, bool, DesignScript.Builtin.Dictionary).
But i’m sure i’m using the correct input element.
Please see attached image
Any Suggestion?

You need to upgrade to BimorphNodes v2.2.8 via the Package Manager which is compatible with Dynamo version 2.0.

The list syntax change in Dynamo 2.0 from {} to [] is the culprit as it breaks the DefaultArgument attribute if set to a list. Pre Dynamo 2.0, setting the DefaultArgument to “{}” returns an empty list, which is the input type CurveFromCADLayers requires for its optional inputs. Post Dynamo 2.0, the same syntax now returns a dictionary, which is an invalid input type for the node and that’s why the invalid input exception is thrown.

I did report this issue on the GitHub before v2.0 was released…but the fate of Dynamo’s list syntax had by that point been sealed! Nevertheless, upgrade to the latest version and everything will work as expected.

1 Like

hi please try this by select model element node as i done in this image biomorphge