Reference ref = new Reference(wall as Element);
ref = Reference(wall)
in python gives an exception that the reference cannot be usedCan one cast a .Net object to its parent object in python (iron python)? I am trying to bandage up someone's dynamo/python script and that one object is mucking it up
In C#, if wall
is of class Wall
and that inherits from Element
, there is no need to cast wall
to Element
. You can just use wall
as is. It is already a Wall
and therefore also an Element
. I would assume the same applies in Python. I suggest you post a code snippet for better understanding.